FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour HOW EXIT FROM A BTNBMP (button)
Posts: 340
Joined: Thu Jan 25, 2007 03:53 PM

HOW EXIT FROM A BTNBMP (button)

Posted: Tue Oct 04, 2011 09:01 AM

HI to all,
i'am not able to exit from a dialog by pressing a button BTNBMP.
this is a small example.
(Of course i need and i want to use BTNBMP)
(EMG suggest ask you)

include "FiveWin.ch"

*
function Main()

local oDlg,obut
local pippo:= space(40)

DEFINE DIALOG oDlg TITLE "TEST" from 0,0 to 250,350 pixel

@10,10 SAY "leave the field empty and click non exit button" OF oDlg pixel
@28,10 GET pippo OF oDlg pixel valid ! empty(pippo)

@90,10 BTNBMP obtn prompt "exit: not possible if empty pippo" OF oDlg ;
ACTION oDlg:End() pixel size 100,20

ACTIVATE DIALOG oDlg CENTERED

return nil

romeo/zingoni

Posts: 1088
Joined: Fri Oct 07, 2005 03:33 PM

Re: HOW EXIT FROM A BTNBMP (button)

Posted: Tue Oct 04, 2011 11:16 AM

Hola

add obtn:lCancel := .T.

regards

Marcelo

Posts: 340
Joined: Thu Jan 25, 2007 03:53 PM

Re: HOW EXIT FROM A BTNBMP (button)

Posted: Fri Oct 07, 2011 03:41 PM

it works !

tks

Posts: 340
Joined: Thu Jan 25, 2007 03:53 PM

Re: HOW EXIT FROM A BTNBMP (button)

Posted: Wed Oct 12, 2011 09:38 AM

..... and how can i DEFAULT it ?

i tried obtn:lDefault := .T.

but it does not works !!

...somethings to got the focus ?
tks

Continue the discussion