Hi Anitha,

Try writing the code in Write method of the form after the super() call.

The address table requires a reference table id and recid for making a
relation with any other  table.

Reference tableid you will get but recids are generated while saving the
record. So even if your code is getting executed in validateWrite it is just
inserting the record without any reference recid. That is why you are not
able to see the record for the first time. Second time when you save the
record the record id is already present hence it is creating a new record in
the address table with the proper recid reference.

Note: This code will be invoked everytime you update the record and
duplicate records may be created.

Regards,
Sumit

On Tue, Nov 18, 2008 at 3:16 PM, Anitha E <[EMAIL PROTECTED]> wrote:

>    Hi ,
>     I am customizing customer form in Ax 4.0.
>
>     When address is entered for the address in Address Tab of the
> customer,the same should be       reflected in Customer Form->SetUp->Alt
> Address.
>
>     I tried in ValidateWrite of Customer Form.
>
>     The problem here is only when i click the save button twice, I see the
> record in the Address          Table as well as Alt Address form. Is this
> a refresh problem?
>
>     I tried giving datasource.refresh and reread in the validatewrite after
> my insertion login. Still not     working.
>
>     I could not figure out the solution for this.
>
>     I would appreciate if you suggest a solution
>
> Regards,
> Anitha
>
> ------------------------------
> Extend your network, join the Microsoft Dynamics AX Knowledge Village at
> LINKEDIN ! <http://www.linkedin.com/e/gis/165338>
> ------------------------------
>
> ------------------------------
> Add more friends to your messenger and enjoy! Invite them 
> now.<http://in.rd.yahoo.com/tagline_messenger_6/*http://messenger.yahoo.com/invite/>
>
> 
>

Reply via email to