TGet bug

Post Reply
User avatar
Enrico Maria Giordano
Posts: 7355
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Contact:

TGet bug

Post by Enrico Maria Giordano »

This is the sample. Try to input 1.25 and you'll get 1.30 on lost focus (xHarbour, BCC55):

Code: Select all

#include "Fivewin.ch"


FUNCTION MAIN()

    LOCAL oDlg

    LOCAL nVar := 0

    DEFINE DIALOG oDlg

    @ 1, 1 GET nVar;
           PICTURE "@EZ 99,999.99";
           RIGHT

    @ 3, 1 BUTTON "&Close";
           ACTION oDlg:End()

    ACTIVATE DIALOG oDlg;
             CENTER

    ? nVar

    RETURN NIL
EMG
User avatar
Manuel Valdenebro
Posts: 706
Joined: Thu Oct 06, 2005 9:57 pm
Location: Málaga-España

Post by Manuel Valdenebro »

Not error for me.
Un saludo

Manuel
User avatar
Enrico Maria Giordano
Posts: 7355
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Contact:

Post by Enrico Maria Giordano »

And what xHarbour release? I'm using the latest from CVS. I suspect the problem is there...

EMG
User avatar
Enrico Maria Giordano
Posts: 7355
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Contact:

Post by Enrico Maria Giordano »

Ok, I found the problem in xHarbour and just reported it to the xHarbour developers mailing list.
This is the sample. Try to input 1.25 and then press F2 twice. You will get
1.30 instead of 1.25.

Code: Select all

#include "Inkey.ch"


FUNCTION MAIN()

    LOCAL nVar := 0

    PUBLIC GetList := {}

    SET CONFIRM ON

    SET KEY K_F2 TO CHANGEPICTURE

    CLS

    @ 10, 10 GET nVar;
             PICTURE "@EZ 99,999.99"

    READ

    RETURN NIL


STATIC FUNCTION CHANGEPICTURE()

    IF M -> GetList[ 1 ]:Picture = "@EZ 99,999.99"
        M -> GetList[ 1 ]:Picture = "@EZ 99999.99"
    ELSE
        M -> GetList[ 1 ]:Picture = "@EZ 99,999.99"
    ENDIF

    RETURN NIL
EMG
Post Reply