Moderators Melba23 Posted March 17, 2016 Author Moderators Share Posted March 17, 2016 Zambi, Yes you can very easily do that - what code have you tried that has not worked? M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
Zambi Posted March 17, 2016 Share Posted March 17, 2016 (edited) $sRet = _CFF_Choose("Ex 5: Select multiple files AND folders (resizeable)", -300, 500, -1, -1, "cd|" & "C:\Program Files (x86)\", "Include\" & "*Adobe*", 2 + 4 + 8 + 16, 20) Hi Melba. I've been trying to modify Ex 5 from the Example 1 file. I changed the 0 to 2 to show only folders, and have been trying different combinations to replace "Default" with an Include/Exclude string that I can't seem to get right. Edited March 17, 2016 by Zambi Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted March 17, 2016 Author Moderators Share Posted March 17, 2016 Zambi, That will not work because I imagine that there are no folders within the root of the C:\ and D:\ drives which contain the text "Adobe" - so the search fails at that point. If you want to search for folders with a specific text then you need to make sure that they exist at the same level in the tree as the root. This finds the single folder containing "Adobe" in "Program Files" on my x32 machine: #include "ChooseFileFolder.au3" _CFF_RegMsg() $sRet = _CFF_Choose("Test", -300, 500, Default, Default, "C:\Program Files", "*Adobe*", 2 + 4 + 8, 20) Remember that the UDF only knows what it sees at the lowest level currently opened - if you ask it to display folders from the root and there are none which match it has no idea if there are any possible matches further down in the tree. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
Zambi Posted March 17, 2016 Share Posted March 17, 2016 Thanks Melba. On my x64 setup, I get the following. So, from the lowest level fed to CFF as a starting point (i.e. C:\Program Files), it looks for a folder containing "Adobe", and from then on, it will only show subfolders (and their subfolders) as long as they contain the same mask. Got it. C:\Program Files\Adobe\Adobe Media Encoder CS5.5 C:\Program Files\Adobe\Adobe Photoshop CS5.1 (64 Bit) C:\Program Files\Adobe\Adobe C:\Program Files\Adobe\Adobe\AdobePatchFiles Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted March 17, 2016 Author Moderators Share Posted March 17, 2016 Zambi, 5 minutes ago, Zambi said: Got it. Great. The UDF syntax is quite complex and you have to play around with it to get the best results. Certainly setting the masks to fairly restrictive settings can often result in nothing being displayed - it is best used when it displays everything and lets the user choose what to select! M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
Mbee Posted June 5, 2016 Share Posted June 5, 2016 (edited) Thanks again, Melba23, for your extraordinary skills and generosity! I previously asked a question, but I decided to go another way... Edited June 5, 2016 by Mbee Decided on a different approach Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted June 5, 2016 Author Moderators Share Posted June 5, 2016 Mbee, Thanks...I think... M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
kosamja Posted September 25, 2016 Share Posted September 25, 2016 Hi Melba, thanks for this excellent UDF. I have one question: Could you add to your UDF option to hide current selection color? I tried adding in _CFF_WM_NOTIFY_Handler function this, but it doesnt work: Case $TVN_SELCHANGINGA, $TVN_SELCHANGINGW Return 1 Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted September 25, 2016 Author Moderators Share Posted September 25, 2016 kosamja, Why would you want to remove the highlight from the current selection? M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
kosamja Posted September 25, 2016 Share Posted September 25, 2016 Because it changes text color of current selection to white. Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted September 25, 2016 Author Moderators Share Posted September 25, 2016 kosamja, And so? Why does this cause a problem> Why do you not want to see the selected item? I am not prepared to even consider such a request without a reasonable reason for hiding the currently selected item - and a simple colour change of the item is not enough. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
kosamja Posted September 25, 2016 Share Posted September 25, 2016 (edited) And what would be reasonable reason? I dont like that blue highlight color and if it cant be changed without changing windows theme I would prefer to remove it (unless it is possible to override it somehow). If it is possible could you then at least add option to have custom highlight color for selected item? Edited September 25, 2016 by kosamja Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted September 25, 2016 Author Moderators Share Posted September 25, 2016 kosamja, Quote I dont like that blue highlight color Fine, you work out how to remove it and let me have the code - I will then see about how it might be added as an option. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
kosamja Posted September 25, 2016 Share Posted September 25, 2016 3 minutes ago, Melba23 said: you work out how to remove it and let me have the code I already did that... Adding this: Case $TVN_SELCHANGINGA, $TVN_SELCHANGINGW Return 1 to _CFF_WM_NOTIFY_Handler function removes color, but then there is problem with expanding: expandcollapse popupFunc _CFF_WM_NOTIFY_Handler($hWnd, $iMsg, $wParam, $lParam) #forceref $hWnd, $iMsg, $wParam ; Create NMTREEVIEW structure Local $tStruct = DllStructCreate("struct;hwnd hWndFrom;uint_ptr IDFrom;INT Code;endstruct;" & _ "uint Action;struct;uint OldMask;handle OldhItem;uint OldState;uint OldStateMask;" & _ "ptr OldText;int OldTextMax;int OldImage;int OldSelectedImage;int OldChildren;lparam OldParam;endstruct;" & _ "struct;uint NewMask;handle NewhItem;uint NewState;uint NewStateMask;" & _ "ptr NewText;int NewTextMax;int NewImage;int NewSelectedImage;int NewChildren;lparam NewParam;endstruct;" & _ "struct;long PointX;long PointY;endstruct", $lParam) Local $hWndFrom = DllStructGetData($tStruct, "hWndFrom") Local $hItem = DllStructGetData($tStruct, "NewhItem") Local $iCode = DllStructGetData($tStruct, "Code") If $hWndFrom = $g_hCFF_TreeView Then ; Set flag for TreeView actioned $g_bCFF_ActiveTV = True ; Clear list selection DllCall("user32.dll", "lresult", "SendMessageW", "hwnd", $g_hCFF_List, "uint", 0x0186, "wparam", -1, "lparam", 0) ; $LB_SETCURSEL ; Check action Switch $iCode Case -2 ; $NM_CLICK ; Fire the dummy control GUICtrlSendToDummy($g_cCFF_Click_Dummy) Case -3 ; $NM_DBLCLK 0xFFFFFFFD ; Fire the dummy control GUICtrlSendToDummy($g_cCFF_DblClk_Dummy) ; Set flag Case $TVN_ITEMEXPANDEDW, $TVN_ITEMEXPANDEDA ; Check autoexpansion flag is not set If Not $g_bCFF_AutoExpand Then ; Fire the dummy control if expanding If DllStructGetData($tStruct, "Action") = 2 Then GUICtrlSendToDummy($g_cCFF_Expand_Dummy, $hItem) EndIf EndIf Case $TVN_SELCHANGEDA, $TVN_SELCHANGEDW ; Fire the dummy control GUICtrlSendToDummy($g_cCFF_Select_Dummy, $hItem) Case $TVN_SELCHANGINGA, $TVN_SELCHANGINGW Return 1 EndSwitch EndIf EndFunc ;==>_CFF_WM_NOTIFY_Handler Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted September 25, 2016 Author Moderators Share Posted September 25, 2016 kosamja, Quote Adding this [...] to _CFF_WM_NOTIFY_Handler function removes color, but then there is problem with expanding: And there lies the problem with amending UDFs. When you have a working solution, please let me know. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
kosamja Posted September 26, 2016 Share Posted September 26, 2016 Problem solved. Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted September 26, 2016 Author Moderators Share Posted September 26, 2016 kosamja, Bravo - but please explain how you did it. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
Nikolas92 Posted December 22, 2016 Share Posted December 22, 2016 Hi Melba, there is bug in windows 10 with Your UDF, it only shows files and folders at root of drive, it doesnt go deeper. Any chance for this bug to be fixed? Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted December 22, 2016 Author Moderators Share Posted December 22, 2016 Nikolas92, I have only just got a Win 10 machine - I will look into it over the holiday period. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
nobbitry Posted December 22, 2016 Share Posted December 22, 2016 (edited) It works here with Windows 10 Pro x64. (Used Example File 1.) Edited December 22, 2016 by nobbitry Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now