Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Stored Procedures
Message
 
À
27/06/1996 12:27:39
Sonny Chouinard
CHCA Computer Systems Inc.
Lachenaie, Québec, Canada
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00002945
Message ID:
00003077
Vues:
39
>>>VFP checks the primary key violation also in the
>>>buffer. So, you can permit changes in the valid
>>>trigger of the item. In that way, VFP doesn't
>>know
>>>there was a primary key violation.
>>>
>>>Sonny
>>>CHCA Informatique
>>
>>So what steps do you take before the user chooses
>>save? What you're saying is that you could check
>>before the user leaves the textbox that contains
>>the primary key. Build you textboxes with a
>custom
>>method that checks?
>
>No, take the valid Method, Check yourself if there
>are duplicate primary key (Try using SELECT SQL or
>an array). If ther is duplicate primary keys,
>return False with a message and the focus will
>stay on that textbox or whatever. If all is
>correct, return TRUE.
>
>METHOD VALID
>
> CHECK PRIMARY KEY
>
> IF DUPLICATE
> =MessageBox('ERROR!')
> return 0
> ELSE
> return 1
> ENDIF
>
>Sonny
>CHCA Informatique

Very good, thank you!
Greg
** ** ** ** ** ** ** ** ** ** **
Gregory Cummines
Visual FoxPro 3.0/5.0
C/C++ Applications
** ** ** ** ** ** ** ** ** ** **
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform