Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Validating An APPEND
Message
From
14/01/2000 11:30:34
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00318164
Message ID:
00318178
Views:
22
>If I do:
>
>APPEND BLANK
>GATHER MEMVAR
>
>or
>
>INSERT INTO MyTable FROM MEMVAR
>
>What's the best way to vaildate the new record to insure
>the new values were added ok?
>
>
>TIA


Kevin,
I'm always afraid of "the best way" :) Let's call this a way :)
scatter name oCompare
lnMembers = amembers(aObjMember,oCompare)
llMisMatch = .f.
for ix = 1 to lnMembers
  if eval("oCompare."+ aObjMember[ix]) # eval("m."+ aObjMember[ix])
    llMisMatch = .t.
    messagebox(aObjMember[ix] + " mismatch")
  endif  
endfor
If it was not memvar but another object (then Gather name objname) then compobj(oBefore,oCompare) would be a shorcut.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform