Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Logic for an Add Button
Message
De
15/03/2002 08:30:34
Dennis Hupe
Boot, Hoof'n Paw Prints
Bloomville, New York, États-Unis
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
Logic for an Add Button
Divers
Thread ID:
00633342
Message ID:
00633342
Vues:
42
As a FP2.6 DOS programmer converting to VFP6.0 still struggling with understanding the code found in \wizards\wizstyle.vcx. So far I have been able to create the top, bottom, next, edit and delete buttons. Now need to code the add and Find button logic.

Not able to figure out how to blank out the fields on the form. I assume on the click code that part of the code could look like this:

IF THIS.Caption = 'Add'
THIS.Caption = 'Save'
THISFORM.cmdNext1.enabled = .F.
THISFORM.cmdPrev1.enabled = .F.
THISFORM.cmdTop1.enabled = .F.
THISFORM.cmdBottom1.enabled = .F.
THISFORM.cmdedit1.enabled = .F.
THISFORM.cmddelete1.enabled = .F.
THISFORM.allowedits = .T.
THISFORM.REFRESH()
ELSE
IF MESSAGEBOX('OK To Save',4+32+256)= 7
=TableRevert()
ELSE
=TableUpdate()
ENDIF
THIS.Caption = 'Add'
THISFORM.cmdNext1.enabled = .T.
THISFORM.cmdPrev1.enabled = .T.
THISFORM.cmdTop1.enabled = .T.
THISFORM.cmdBottom1.enabled = .T.
THISFORM.cmdEdit1.enabled = .T.
THISFORM.cmdDelete1.enabled = .T.
THISFORM.allowedits = .F.
THISFORM.REFRESH()
ENDIF

Could someone help me fill in the blanks? Also would appreciate a tip on how to code a Find Button.

Thanks in advance for any assistance.
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform