Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Will I get Version 9.0 free if I just purchased 8.0
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00936280
Message ID:
00937088
Vues:
13
While I've got you on the line, please accept this bug report for VFP 8 and 9. Sergey "worked" the work around. I sent it to the "send comments" link in the help screen - but the auto-responds indicated that there may not be engough time to review every message and suggested some links to assure it would be reported - but the VFP link was broke.

Thanks!

* I have noticed {ENTER} behavior that just don't seem right! The
* attached form has two text boxes. Using tab to navigate at first,
* Change the value in the top text box and press {Enter}. Back tab
* to the text, and press enter. Note the value changes to 0. Now,
* backtab, change to a non zero value and [forward] tab. Back and
* forward tab again. The value DOES NOT change to zero.

* Note: VFP 8 Help does not list the "Z" format option for
* textboxes. Spinners do have "Z". I use it in textboxes anyway
* and it works. Even with "Z", {Enter), after changing the value
* will still zero it out

* Is this "expected behavior"? Is there a way to avoid it?

* THIS work around works in "visual" and PRG textbox objects in 8
* I could not make it work in 9 with this sample
* add property to in textbox init and set control source to that property
* TextBox Init
* this.addproperty('nTextValue',0)
* this.controlsource="this.nTextValue"

* Enter Key Zeros Out Console
ON ERROR do prgError
PUBLIC frmEnter
frmEnter=CREATEOBJECT('clsForm')
WITH frmEnter
.addobject('TopLabel','clsLabel')
.toplabel.top=10
.toplabel.caption=[Top]
.addobject('TopText','clsTextBox')
.toptext.top=10
.addobject('BotLabel','clsLabel')
.Botlabel.top=40
.Botlabel.caption=[Bot]
.addobject('BotText','clsTextBox')
.Bottext.top=40
.SHOW
ENDWITH
READ events
CANCEL

DEFINE CLASS clsForm as Form
caption=[Enter key will Zero "changed" value]
bindcontrols=.f.
visible=.t.
PROCEDURE release
this.QueryUnload
ENDPROC
PROCEDURE queryunload
CLEAR EVENTS
ENDPROC
ENDDEFINE

DEFINE CLASS clsTextBox as TextBox
*bindcontrols=.f.
width=100
format="RZ"
inputmask="9999999.99"
left=100
visible=.t.
value=0
ENDDEFINE

DEFINE CLASS clsLabel AS LABEL
WIDTH=100
LEFT=0
VISIBLE=.T.
ENDDEFINE

PROCEDURE prgError
ON ERROR
MESSAGEBOX([Error])
ON ERROR do prgError
ENDPROC
* End of Enter Key Console
Imagination is more important than knowledge
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform