Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Visual Max Frame - 'Primary Key' of Free tables
Message
 
 
To
25/07/2000 19:37:35
General information
Forum:
Visual FoxPro
Category:
Third party products
Miscellaneous
Thread ID:
00396838
Message ID:
00396866
Views:
17
>Hi,
>
>I have several free tables that I wish to edit via frmDEGridNav2Pages.
>
>Is there any behavior built into this class that enforces the uniqueness of an entered index ? I mean truly unique, same as a primary key, but not using a DBC.
>
>TIA,
>
>Alex

Alex,
As Ed said, you could use a Candidate key to enforce this with VFP but this generates a nasty error 1884 (Uniqueness of index "indexname" is violated) if you violate it. You can avoid this by using either of the following VMP tools:

1. Use an instance of CusCKCheck in XXFWCTRL.VCX (Candidate Key check) in conjunction with a textbox or spinner. See the zRreadMe for notes on how to implement it.
2. In the ActionOnValid of your data entry controls, add code to call X3CKCHEK with the necessary parameters. This will return a logical value based on whether value exists in the table. The CusCKCheck class is actually a wrapper to this utility but it is a little easier to use because of the visual aspect of setting properties in the property sheet.

HTH.
Larry Miller
MCSD
LWMiller3@verizon.net

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

Click here to load this message in the networking platform