Look this code:
Code: Select all
#include <fivewin.ch>
func main()
LOCAL oWnd
XBROWSER {10,20,30,40}
DEFINE WINDOW oWnd
ACTIVATE WINDOW oWnd
XBROWSER {10,20,30,40}
return 0
Code: Select all
#include <fivewin.ch>
func main()
LOCAL oWnd
XBROWSER {10,20,30,40}
DEFINE WINDOW oWnd
ACTIVATE WINDOW oWnd
XBROWSER {10,20,30,40}
return 0
Code: Select all
function Main()
local oWnd, oDlg
DEFINE WINDOW oWnd
ACTIVATE WINDOW oWnd CENTERED
DEFINE DIALOG oDlg
ACTIVATE DIALOG oDlg CENTERED
return nil
I don't know who you are dear Jack, but please read the question carefully, we're talking about the Xbrowser command, not of xbrowse() func,Jack wrote:Hi,
You have to place the XBROWSE bitween DEFINE WINDOW AND ACTIVATE WINDOW .
Code: Select all
#include <fivewin.ch>
proc main()
LOCAL oWnd
? GetWndApp() //0
XBROWSER {10,20,30,40}
DEFINE WINDOW oWnd
ACTIVATE WINDOW oWnd
? GetWndApp() // value
XBROWSER {10,20,30,40} //no windows, because parent is closed
SetWndApp(0)
? GetWndApp() // not change!
XBROWSER {10,20,30,40} //no windows, because SetWndApp(0) does not works....
#include "FiveWin.ch"My opinion is that should be possible create an application
that shows a dialog after the main window is closed
ukoenig wrote: oWnd:Hide()
Code: Select all
#include <fivewin.ch>
func main()
LOCAL oWnd
XBROWSER {10,20,30,40}
DEFINE WINDOW oWnd
ACTIVATE WINDOW oWnd
// The SETUP clause is used because the command XBROWSER has no "OF" clause (PARENT)
XBROWSER {10,20,30,40} SETUP ( oBrw:oWnd:oWnd := oWnd )
return nil
Code: Select all
#include "fivewin.ch"
function Main()
local oWnd, oDlg
DEFINE WINDOW oWnd
ACTIVATE WINDOW oWnd CENTERED
//SetWndDefault( oWnd )
DEFINE DIALOG oDlg OF oWnd //OF GetWndDefault()
ACTIVATE DIALOG oDlg CENTERED
return nil