TMultiGet [Solved]

TMultiGet [Solved]

Postby Enrico Maria Giordano » Sun Jun 08, 2008 6:16 pm

In the following sample you will notice that the Enter key doesn't fire the ON CHANGE clause:

Code: Select all  Expand view
#include "Fivewin.ch"


REQUEST HB_GT_GUI_DEFAULT


FUNCTION MAIN()

    LOCAL oDlg, oGet

    LOCAL cVar := ""

    DEFINE DIALOG oDlg

    @ 0, 0 GET oGet VAR cVar MEMO;
           SIZE 100, 30;
           ON CHANGE TONE( 440, 1 )

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

    ACTIVATE DIALOG oDlg;
             CENTER

    RETURN NIL


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

Re: Bug in TMultiGet

Postby Enrico Maria Giordano » Sun Jun 08, 2008 6:18 pm

A possible fix in KeyChar() method:

Code: Select all  Expand view
   if nKey == VK_RETURN .and. ;
      lAnd( GetWindowLong( ::hWnd, GWL_STYLE ), ES_WANTRETURN )
      ::oWnd:nLastKey = 0
      if ::bChange != nil  // EMG
         Eval( ::bChange, nKey, nFlags, Self )  // EMG
      endif  // EMG
      return nil
   endif


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

Postby Otto » Sun Jun 08, 2008 6:25 pm

Enrico, is this only an error on veriosn 8.05?
Thanks in advance
Otto
User avatar
Otto
 
Posts: 5994
Joined: Fri Oct 07, 2005 7:07 pm

Postby Enrico Maria Giordano » Sun Jun 08, 2008 6:27 pm

No, it is an old bug.

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


Re: TMultiGet

Postby Enrico Maria Giordano » Sun Mar 22, 2009 10:40 am

Just to take this bug up. :-)

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



Return to Bugs report & fixes / Informe de errores y arreglos

Who is online

Users browsing this forum: No registered users and 5 guests