He cant know more Dwarvish than perhaps some words as this language is kept secret and Aragorn wasnt really a fried of the Dwarves; its illogical that Aragorn knows what Gimli, save if its a commonly used sentence.
He does speak Elvish but this is no elvish but Rohirric, reproduced in Old English (just compare the words with modern English...)