Folder check

Folder check

Postby TimStone » Fri Aug 31, 2018 10:32 pm

Consider the following:

Code: Select all  Expand view

DEFINE DIALOG oWdlg1 BRUSH oBrush RESOURCE "WOMAINw" OF oWnd TITLE cTitle
REDEFINE FOLDEREX oEditWork:oFld ID 356 OF oWdlg1 ;
    PROMPT "   General   ", "   Parts   ", "   Labor   ", "   Recommend   ", "   Totals   ", "   Inspect   ", "   Costing   ", "  Services  ", "   Attachments   " ;
    DIALOGS "WOGENw", "WOPARw", "WOLABw", "WORECw", "WOTOTw", "WOINSw", "WOCSTw", "WOSVCw", "WOATTw" ;
    ON CHANGE ( oEditWork:FolderCheck( ), oWdlg1:update() ) ROUND 5 TRANSPARENT
 


I have a "security" file with flags for access to various elements of the program. In the example above, I want to be able to show, but not activate, some of the folder prompts. That means, although the Totals Folder tab is shown, if they click on it, nothing happens.

Is there a setting in the folders control that allows me to do this ? I realize I could simply filter which tabs are shown, but those folders are all defined in the program, and eliminating some will cause a multitude of problems.

Thanks ... I'll be someone has this answer ....
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2927
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: Folder check

Postby cnavarro » Fri Aug 31, 2018 11:23 pm

Tim
This control has a DATA aEnable ( array, len( aEnable ) equal len( aDialogs ) )
This DATA contains logicals values state of each dialog: .T. -> Enable, .F. .> Disable
oFldEx:aEnable := { .T., .F. }
In this case, second dialog is disabled
Cristobal Navarro
Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noción del tiempo
El secreto de la felicidad no está en hacer lo que te gusta, sino en que te guste lo que haces
User avatar
cnavarro
 
Posts: 6522
Joined: Wed Feb 15, 2012 8:25 pm
Location: España

Re: Folder check

Postby TimStone » Tue Sep 04, 2018 10:27 pm

Thank you. That works perfectly for me.
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2927
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA


Return to FiveWin for Harbour/xHarbour

Who is online

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