sort a vector

arrCompany [2]([6]("wowo","Office:213214219","Mobile:2132123213","3","2","Other:21321"),[6]("bill","Office:66565","Mobile:243333","3","2","Other:5555"),[6]("testg","Office:21313123","Mobile:123324324","3","2","Other:3423432"))



Hi,

How can I sort the above vector by the first element....the first element like wowo is the name and then the following office,mobile and other belongs to wowo...therefore I need it sorted by name.

Help anyone?

I want it to look like this arrCompany [2]([6]("bill","Office:66565","Mobile:243333","3","2","Other:5555"),[6]("testg","Office:21313123","Mobile:123324324","3","2","Other:3423432"),[6]("wowo","Office:213214219","Mobile:2132123213","3","2","Other:21321"))



Thanks

Carl
Plz wrap your code around code tags like this:

insert code

Second, you should make a class for that ;)
That will make it a lot easier!
Check the tut on this site: http://www.cplusplus.com/doc/tutorial/classes/

Third, please post in the appropriate forum next time (beginners).

-Xander
Topic archived. No new replies allowed.