Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP CRC Function
Message
 
To
21/12/2012 10:05:37
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
Miscellaneous
Thread ID:
01560390
Message ID:
01560400
Views:
101
>Hi All,
>
>Anyone know the code to implement the SYS(2007) checksum calculation?

SYS(2007, cExpression, [, nSeed, [, nFlags]])

ENTER IN THE COMMAND WINDOW
HELP SYS(2007)

I use it to compare 2 values to see if they no longer match. Such as when updating a remote MySQL database. No need to send the update over the wire if no changes where made. Note that I am leaving out the flags, etc here to simplify but you should get the idea.
nOrgCkVal =  SYS(2007,CustName)
...user edits data here...
before save
if nOrgCkVal <> SYS(2007,CustName)
  update the server cause the data has changed
endif
Beer is proof that God loves man, and wants him to be happy. - Benjamin Franklin
John J. Henn
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform