Get on Button Bar

Get on Button Bar

Postby Colin Haig » Sun Jun 19, 2011 2:42 am

I am having problems with a get on a buttonbar

type a value in the get and press enter - the first MsgInfo is blank the second MsgInfo has the value typed in.
Using a valid clause and using the bKeyDown to process the valid produces the same result
Code: Select all  Expand view

 @15,65 GET oFindInvc VAR cJbNo picture '@!' UPDATE of oBar;
            SIZE 60,20 ;
            FONT oFont ;
            PIXEL
            oFindInvc:bKeyDown = { | nKey | If( nKey == VK_RETURN, (MsgInfo(cJbNo),MsgInfo(cJbNo)),) }
 

What I have is a buttonbar with an Exit and Find Buttons and a get field (the get field is hidden initially) - when the
find button is pressed the get is shown - the user enters a value and hits the enter key - the value is searched for and
if found sets a scope and displays a browse with the resulting records.

Using the xHarbour and FWH 11.05

Colin
Colin Haig
 
Posts: 310
Joined: Mon Oct 10, 2005 5:10 am

Re: Get on Button Bar

Postby Enrico Maria Giordano » Sun Jun 19, 2011 8:26 am

Try

Code: Select all  Expand view
oFindInvc:bKeyDown = { | nKey | If( nKey == VK_RETURN, (oFindInvc:Assign(),MsgInfo(cJbNo)),) }


If it doesn't work, can I see a little sample of the problem that I can compile and run here, please?

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

Re: Get on Button Bar

Postby Colin Haig » Sun Jun 19, 2011 8:48 am

Thanks Enrico - that worked fine.

Cheers

Colin
Colin Haig
 
Posts: 310
Joined: Mon Oct 10, 2005 5:10 am


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 57 guests