Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Please Help !!! Valid Method ???
Message
De
01/09/1998 03:28:22
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00131529
Message ID:
00131806
Vues:
27
>Do you know why when you return .F. within a valid method of textbox in a grid it lose the focus anyway if you click on another object.
>
>Note: the Textbox control work fine if it's not in a grid
>
>All idea or suggestion will appreciate
>Thank's in advance
Hi Rock,
As Ken pointed out it's documented in BUG: Focus Changes Even Though Grid Text Box Valid Returns .F. with no workaround. I commented there a workaround but think it'll never appear there (huh just 255 chars limited commenting).
Workaround consists of flagging hanging validations and grid.valid checking it.
* Custom grid or form property lHangingValidation (Grid preferred)
* A valid.event of textbox
if ....
  lHangingValidation = .t.
else
  lHangingValidation = .f.
endif
return !lHangingValidation

* Grid.valid
if ....
   return .f.
else
   return !lHangingValidation
endif
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform