Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Determining the current record prior to copy
Message
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00826011
Message ID:
00826034
Views:
20
Assuming that you're copying record from WORKSTYLE, try
m.OldKey = WORKSTYLE.KEY3
IF oForm.Copy
  REPLACE WORKSTYLE.MOC008 WITH "", ;
    WORKSTYLE.MOC042 WITH m.OldKey
ENDIF
SELECT MODACAD
oToolbar.DefaultSave()
>Sorry Cetin
>
>
>IF oForm.Copy
>REPLACE WORKSTYLE.MOC008 WITH ""
>REPLACE WORKSTYLE.MOC042 WITH WORKSTYLE.KEY3
>ENDIF
>SELECT MODACAD
>oToolbar.DefaultSave()
>
>
>The code above is foxpro and what the top line is which is supplied by our danish vendor is saying only when a user tries to copy then replace the moc008 field on the NEW COPIED record to nothing. The next line will replace the moc042 field with the value from key3. This is the problem I have it will copy the key3 value after the copy to the moc042 for the new record. I want to copy the key3 field value from the old record and store it in the moc042 of the newly created copied record.
>
>Many Thanks
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform