what is the elegant method to build a screen full of GETs, TABPAGES, ecc. and avoid the sequential display (slow refresh) of the objects that you are populating ?
it would be possible to display an hourglass or a bitmap like 'wait...' in center of the drawingarea that hides the preparation of everything ?
it is terrible to show the composition of a screen piece by piece
max
method to building a screen with many objects
Re: method to building a screen with many objects
hi Max,
every Xb-Part have Parameter <lVisible> at New() / Create() which is DEFAULT .T.
use Dialog with .F. and when all finsh "just" oDialog:Show()
remember to "fill" Listbox() ComboBox() or "Browse" before "Show" Dialog
p.s. opposite of o:Show() is o:Hide()
every Xb-Part have Parameter <lVisible> at New() / Create() which is DEFAULT .T.
use Dialog with .F. and when all finsh "just" oDialog:Show()
remember to "fill" Listbox() ComboBox() or "Browse" before "Show" Dialog
p.s. opposite of o:Show() is o:Hide()
greetings by OHR
Jimmy
Jimmy
Re: method to building a screen with many objects
Code: Select all
DCGETOPTIONS ;
BUSYMESSAGE 'Building Screen Objects. Please wait..' COLOR GRA_CLR_DARKGREEN
The eXpress train is coming - and it has more cars.
Re: method to building a screen with many objects
Take a look at DC_MergeGetlists(), which still is a good way to create objects on tabpages only if they are needed.
Jimmy ("Auge_ohr") doesn't use eXpress++, so forget what he mentions here.
Jimmy ("Auge_ohr") doesn't use eXpress++, so forget what he mentions here.
Best regards,
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Re: method to building a screen with many objects
I solved the problem by creating the dialog window with Visible = .F. and after building all GETs, TABPAGE, etc. i used:
DCGETOPTIONS EVAL {||dialog:show()}
If I've more time I will try Tom's solution using DC_MergeGetlists(), which sould be more efficient
Thanks to all for the help
DCGETOPTIONS EVAL {||dialog:show()}
If I've more time I will try Tom's solution using DC_MergeGetlists(), which sould be more efficient
Thanks to all for the help
Re: method to building a screen with many objects
Hi Maxz,
Just wondering how many objects you have in a screen? It looks as you are concerned about speed, while I never had issues with it in 'normal' screens in my application.
When using tabpages, you only create the objects if that tabpages gets focus. WIth DC_MergeGetlists you add the new tab-content to the getlist.
Since a few months there is also a modification in eXpress++ so 'non-visible' objects are not refreshed with a dc_getrefresh(). Also with dc_getrefresh() you can define which objects needs to be refreshed. In a lot of cases you don't need to refresh everything.
See the sample in XDemo - Sample program 5 - MergeGets 2.
Just wondering how many objects you have in a screen? It looks as you are concerned about speed, while I never had issues with it in 'normal' screens in my application.
When using tabpages, you only create the objects if that tabpages gets focus. WIth DC_MergeGetlists you add the new tab-content to the getlist.
Since a few months there is also a modification in eXpress++ so 'non-visible' objects are not refreshed with a dc_getrefresh(). Also with dc_getrefresh() you can define which objects needs to be refreshed. In a lot of cases you don't need to refresh everything.
See the sample in XDemo - Sample program 5 - MergeGets 2.
Re: method to building a screen with many objects
hi Tom,
to "hide" Control when build Screen is not only for Xbase++ / Express++
it is for all GUI Apps while "paint" Control need much Time.
Marx is a new User and he should know what Xbase++ Original "can do"
Express++ is based on Xbase++ so all what Xbase++ "can do" will work with Express++
i agree that Express++ have many Things which are more "Powerfull"
as Marx have a Express++ License (?) he should use it.
to "hide" Control when build Screen is not only for Xbase++ / Express++

it is for all GUI Apps while "paint" Control need much Time.
Marx is a new User and he should know what Xbase++ Original "can do"
Express++ is based on Xbase++ so all what Xbase++ "can do" will work with Express++
i agree that Express++ have many Things which are more "Powerfull"
as Marx have a Express++ License (?) he should use it.
greetings by OHR
Jimmy
Jimmy
Re: method to building a screen with many objects
Hi, Jimmy.
The HIDE clause does that for eXpress++-users. It just maybe confusing to talk about object properties while this is wrapped by the tool used here. Besides, object properties can and should be used although they are created with eXpress++!
Anyway, hiding objects does not improve the speed of building a dialog.
Maxz: There is a HIDE option in DCGET OPTIONS, which does that for you. You don't need to set an o:Visible := .F. at every object.
The HIDE clause does that for eXpress++-users. It just maybe confusing to talk about object properties while this is wrapped by the tool used here. Besides, object properties can and should be used although they are created with eXpress++!
Anyway, hiding objects does not improve the speed of building a dialog.
Maxz: There is a HIDE option in DCGET OPTIONS, which does that for you. You don't need to set an o:Visible := .F. at every object.
Best regards,
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Re: method to building a screen with many objects
Yes Tom, I understood your suggestion perfectly but my quick and acceptable solution was this:
- I create always an XbpDialog (oDialog) to generate the screen where to build the GETs [ XbpDialog():New(oMainWindow, , aPos, aSize, , .F. ) ]
- only this part is in :hide() state during the process of population of the GETs
- all GETs are parent of oDialog
- when the DCREAD GUI loop starts I put the dialog box in :Show() state
The result is that the user waits 1 or 2 seconds and the screen appears complete with everything
for me this is already a success!! - What do you think?
ps. maybe it would be better if I did an intensive course with you ...
- I create always an XbpDialog (oDialog) to generate the screen where to build the GETs [ XbpDialog():New(oMainWindow, , aPos, aSize, , .F. ) ]
- only this part is in :hide() state during the process of population of the GETs
- all GETs are parent of oDialog
- when the DCREAD GUI loop starts I put the dialog box in :Show() state
The result is that the user waits 1 or 2 seconds and the screen appears complete with everything
for me this is already a success!! - What do you think?
ps. maybe it would be better if I did an intensive course with you ...

Re: method to building a screen with many objects
Tom, I would like to experiment with your suggestion for creating screens as the user tries to access a TABPAGE
if I understand correctly, the technique is to populate the next TABPAGE only when the object is made active his focus, right ?
for example:
@ 0,0 DCTABPAGE oTabPage2 CAPTION 'tabpage2' ;
RELATIVE oTabPage1 ;
GOTFOCUS {||PreparePage2()}
@ 0,0 DCTABPAGE oTabPage3 CAPTION 'tabpage3' ;
RELATIVE oTabPage2 ;
GOTFOCUS {||PreparePage3()}
within the PreparePageN() routine it is sufficient to create the GETs and use DC_MergeGetlists ?
if I understand correctly, the technique is to populate the next TABPAGE only when the object is made active his focus, right ?
for example:
@ 0,0 DCTABPAGE oTabPage2 CAPTION 'tabpage2' ;
RELATIVE oTabPage1 ;
GOTFOCUS {||PreparePage2()}
@ 0,0 DCTABPAGE oTabPage3 CAPTION 'tabpage3' ;
RELATIVE oTabPage2 ;
GOTFOCUS {||PreparePage3()}
within the PreparePageN() routine it is sufficient to create the GETs and use DC_MergeGetlists ?