bb.donnay-software.com

Donnay Software Web Forums
It is currently Wed Oct 16, 2019 10:55 pm

All times are UTC - 7 hours




Post new topic Reply to topic  [ 2 posts ] 
Author Message
PostPosted: Tue Oct 01, 2019 3:12 pm 
Offline
User avatar

Joined: Thu Jan 28, 2010 1:33 pm
Posts: 384
Location: Republica Dominicana
Hello Roger
In Express there is a function that does not let me load a screen more than one

_________________
Nolberto Paulino
Regards


Top
 Profile  
 
PostPosted: Wed Oct 02, 2019 11:18 am 
Offline

Joined: Thu Jan 28, 2010 7:07 am
Posts: 603
Location: Alachua, Florida USA
This is what i used to use (before i retired :) )

if is_this_window_open( cWindowName )
return(nil)
endif

***************************
function is_this_window_open( cWindowName )
***************************
local lRetval:=.f.,i
local oMainwindow:=SetAppwindow()
local nDeskTopWindows := Len(AppDeskTop():childList())
local nChildWindows,aChildList

// added in case oMainwindow does not have drawing area
IF !ismembervar(oMainWindow,"drawingarea")
return(lRetval)
ENDIF
nChildWindows := Len(oMainWindow:drawingarea:childList())
aChildList := oMainWindow:drawingarea:childList()


IF (nDesktopWindows >2 .OR. nChildWindows>1) .AND. !Empty(cWindowName)
FOR i := 1 TO nChildwindows
IF ismembervar(aChildList[i],"title")
IF aChildList[i]:title == cWindowName
err_msg("Cannot open "+cWindowName+" twice")
SetAppFocus(aChildList[i])
lRetVal := .t.
EXIT
ENDIF
ENDIF
NEXT
ENDIF
return(lRetval)

_________________
Brian Wolfsohn
Retired and traveling around the country to music festivals in my RV.
www.breadmanrises.com
FB travel group: The Breadman Rises


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC - 7 hours


Who is online

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


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group