Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Stop Append blank
Message
From
20/11/2001 15:34:25
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00584174
Message ID:
00584179
Views:
26
>Hi everybody,
>
>I have a table with primary PK KeyID. This KeyID is auto-generated using default value in the field. Now, user opens table in command window and do append blank. GetNextID fails and returns 0. So, we ended with couple of records with 0 as PK.
>
>How can we stop APPEND BLANK if GetNextID fails?
>
>Thanks in advance.

Why would GetNextID fail?

Perhaps VFP can't find this function.

I place the function which I believe is the equivalent into stored procedures. This works even if user issues APPEND BLANK from the command window, or adds a new record from the BROWSE window.

HTH, Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform