Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Save doubles ?
Message
 
 
To
25/08/2000 11:14:22
Koos Veel
Gamma Research
Aruba
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
00409253
Message ID:
00409257
Views:
19
>Hello,
>
>A discussion that comes back regularly in our shop is the following:
>In a data entry form for widgets you have to enter a description and a number only. No two widgets can have the same number. When you save the entry the program must check if the widget number does not already exist.
>What would be the best code for this ? (there are two situations, 1. it is a new entry, 2. it is an edit of an existing entry).
>Anybody has wisdom here ?
>
>Thanks,

We have two modes for our forms: Add and Edit.

If you are Add mode the candidate key is checked before a save is performed. If the check fails, a suitable error message is displayed.

If you are in Edit mode and the seek/indexseek/locate fails to find the record you are currently editing (via record number) then another suitable message is displayed.

HTH.
Larry Miller
MCSD
LWMiller3@verizon.net

Accumulate learning by study, understand what you learn by questioning. -- Mingjiao
Previous
Reply
Map
View

Click here to load this message in the networking platform