PDA

View Full Version : QML Contacts and Importing an individual from a list



TejWC
10th May 2011, 17:30
So I have some QML code that has two ContactModel instances. One is from the local system (getting the already installed contacts), and the other one is from an external vCard that I loaded up. When I want to do is copy a specific contact from one ContactModel to the other. Lets say one manager is called "conModelA" and the other one is called "conModelB". So I tried "conModelA.saveContact(conModelB.contacts[2])" but that doesn't work because conModelB.contacts[anyIndex] is always undefined. Has anybody else tried something similar? Thanks.

eklekt
18th May 2011, 11:18
I think, you need to use conModelB.contacts.get(anyIndex) instead conModelB.contacts[anyIndex]