Each contactperson has its own id (field contactpersonId).
You must set this id like
Contactperson.contactPersonId = NumberSeq::newGetNum(CompanyInfo::numRefContactPersonId()).num();

If you get also the message "contactperson does already exist" please check your number sequence.

Regards
Denis Unger


-----Urspr�ngliche Nachricht-----
Von: Michael Huber [mailto:[EMAIL PROTECTED]
Gesendet: Freitag, 16. Juli 2004 14:51
An: [EMAIL PROTECTED]
Betreff: [development-axapta] adding to CustTable and ContactPerson


Dear Axapta-Developers,

i want to add some information to the tables custtable and contactperson.
for this i copied a job wich was originally coded and used by our AX-Developer.

i modified the job to fit to the data i want to import.

the job should first import the customer information to cust table
and then import the contact person data (related to the customer info).

when i try to run the job axapta creates a message wich says that the
contactperson i want to import does already exist. But i am shure that it
does not!

In the debugger i can see that the job does anything i want, the data is
mapped to the right fields an so on. but then the job exits at this line:

contactPerson.insert();

But if i create a copy of the table contact person and import to this (emty) table
all works perfectly, the company gets imported to custtable and the persons get
imported to copyofcontactperson...

i don�t understand this behavior...

please help me!

best regards,

michael










Michael Huber
Systemadministration
RUETZ TECHNOLOGIES
Ingolst�dter Str. 18
80807 M�nchen
Tel: +49 / 89 / 356 10-151
Fax: +49 / 89 / 356 10-111
mailto: [EMAIL PROTECTED]
Internet: http://www.ruetz.de <http://www.ruetz.de>







Yahoo! Groups Links







Yahoo! Groups Sponsor
ADVERTISEMENT
click here


Yahoo! Groups Links

Reply via email to