Page 1 of 1

Fivehm/multi thread vs child/MDI dialog

PostPosted: Sun Dec 09, 2007 2:24 am
by ShumingWang
Hi,
Multi thread use of harbour+fwhm like No modal/ Child dialog?

function myfun()
local odlg
define dialog odlg

browse ...
redefine get id 201 of odlg
redefine button id 202 of odlg action (call thread 2 myfun1() )

activate dialog odlg

return

function myfun1()
local odlg

define dialog odlg

browse ...
redefine get id 201 of odlg
redefine button id 202 of odlg action myfun2()

activate dialog odlg

return

after call myfun1(), there are 2 dialogs like 2 no modal dialogs ?

Thanks !

Shuming Wang

PostPosted: Sun Dec 09, 2007 8:41 am
by Antonio Linares
Shuming,

dialogs are non modal between them, unless you specify OF ... or the previous dialog has focus:

DEFINE DIALOG oDlg2 OF oDlg1

PostPosted: Mon Dec 10, 2007 5:06 am
by ShumingWang
Antonio,
How could I switch from one dialog to another freely if they are non dialogs?

Normaly we call and create another dialog odlg2 after ckick /press the first dialog .

function main()
define dialog odlg1

redefine button id 101 of odlg1 action createdialog2()
activate dialog odlg1

function creatdialog2()
define dialog odlg2
redefine ...
activate dialog odlg2.
return

You must close odlg2,then you can back/enter/active odlg1.

Regards!
Shuming Wang

PostPosted: Mon Dec 10, 2007 8:47 am
by Antonio Linares
Shuming,

ACTIVATE DIALOG oDlg NOWAIT

that will execute it as non modal

PostPosted: Tue Dec 11, 2007 1:34 am
by ShumingWang
Antonio,

The odlg2 seems does not work properly ,for example, xbrowse unmoveable .
Regards!

Shuming Wang

PostPosted: Tue Dec 11, 2007 12:50 pm
by Antonio Linares
Shuming,

Please provide a small and self contained PRG to test, thanks

Global Flag for 2007 style - Requested

PostPosted: Wed Dec 12, 2007 8:58 pm
by nageswaragunupudi
Mr Antonio

I renew my request for providing a global flag for 2007 style, instead of having to specify at each and every instance of menu. bar, msgbar. popmenus spread over in many modules of of the application.

This time I managed by changing xcommands' translates, but I normally do not like to modify FWH commands.

For reconsideration