Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 04/15/2020 in all areas

  1. I'm trying to automate the connection to a WiFi network through the WPS mechanism so I though I would record the clicks of the process. However, when I run the code, it doesn't do anything...This is my code: #region --- Au3Recorder generated code Start (v3.3.9.5 KeyboardLayout=0000040A)  --- #region --- Internal functions Au3Recorder Start --- Func _Au3RecordSetup() Opt('WinWaitDelay',100) Opt('WinDetectHiddenText',1) Opt('MouseCoordMode',0) Local $aResult = DllCall('User32.dll', 'int', 'GetKeyboardLayoutNameW', 'wstr', '') If $aResult[1] <> '0000040A' Then   MsgBox(64, 'Warning', 'Recording has been done under a different Keyboard layout' & @CRLF & '(0000040A->' & $aResult[1] & ')') EndIf EndFunc Func _WinWaitActivate($title,$text,$timeout=0)     WinWait($title,$text,$timeout)     If Not WinActive($title,$text) Then WinActivate($title,$text)     WinWaitActive($title,$text,$timeout) EndFunc _AU3RecordSetup() #endregion --- Internal functions Au3Recorder End --- _WinWaitActivate("classname=Shell_TrayWnd","") MouseClick("left",1143,12,1) _WinWaitActivate("Network Connections","") MouseClick("left",130,273,1) MouseUp("left") _WinWaitActivate("classname=Shell_TrayWnd","") MouseClick("left",1143,19,1) #endregion --- Au3Recorder generated code End --- Not sure if there are specific classes to replace the clicks for something more specific like a built-in function. Otherwise,so you know why the click action is not working? Thanks!
    1 point
  2. Because WM_NOTIFY messages are sent to the parent window. So use GUIRegisterMsg20(_WinAPI_GetParent($hTV), $WM_NOTIFY, WM_NOTIFY)
    1 point
  3. CrshOverride, Welcome to the AutoIt forums. I am delighted that you find my UDF useful - and sorry that you appear to have run into some problems using it. But I do not understand the problem that you have with the GUI closing when you return from the _CFF_Embed call - the UDF does nothing to close the main GUI at that point, all it does is delete the TreeView content which can be restored without problem. In fact the Example_3 script in the UDF zip shows 3 embedded TreeViews operating within the main GUI which remains open until it is deliberately closed by the user. I attach a simple example showing how I would use the function, check the results and the GUI content and loop until everything is good ( which means: a file selected + some content in the input + checkbox NOT checked). And you are correct that when the _CFF_Embed function is running the main GUI [X] is ignored - you need to end the function using {ESC} before the main GUI becomes active again. I can easily add something to the function to look for that event and return immediately setting a suitable @error value which will allow the user to exit the script. I have added some suggested code in the example script - but of course it does not work at the moment as the current UDF does not return the @error value! Here is the example script: #include <GUIConstantsEx.au3> #include <MsgBoxConstants.au3> #include <ChooseFileFolder.au3> $hGUI = GUICreate("Test", 500, 500) GUISetBkColor(0xC4C4C4) $cTV = GUICtrlCreateTreeView(250, 10, 200, 400) $cInput = GUICtrlCreateInput("", 10, 10, 200, 20) $cCheckbox = GUICtrlCreateCheckbox("Test", 10, 100, 200, 20) $cLoad = GUICtrlCreateButton("Load Tree", 10, 190, 80, 30) GUISetState() ; Register UDF message handler _CFF_RegMsg() While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE Exit Case $cLoad While 1 $sRet = _CFF_Embed($cTV) ; THIS DOES NOT WORK WITH THE CURRENT UDF - IT IS A SUGGESTION FOR HOW IT MIGHT BE INCORPORATED ; Check for $GUI_EVENT_CLOSE detected by the function If @error = 99 Then ; Specific error code detected- so the user can exit directly Exit EndIf ; END OF SUGGESTION ; Now do your validation If $sRet = "" Then MsgBox($MB_SYSTEMMODAL, "Ooops!", "No file selected!") ; In each of these fail cases the tree reopens ElseIf GUICtrlRead($cInput) = "" Then MsgBox($MB_SYSTEMMODAL, "Ooops!", "No base input selected!") ElseIf GUICtrlRead($cCheckbox) = $GUI_CHECKED Then MsgBox($MB_SYSTEMMODAL, "Ooops!", "Checkbox was checked!") Else ; All good so carry on ExitLoop EndIf WEnd If MsgBox($MB_SYSTEMMODAL + $MB_YESNO, "All good!", "Close GUI?") = $IDYES Then Exit EndIf EndSwitch WEnd I hope this helps - if not then I have to assume there is something in your code which is closing your GUI - so can you please post your script, or a simplified version of it so that I can take a look. M23
    1 point
  4. It works perfect for me. (I did not test too much. just $hParent stuff) Saludos
    1 point
  5. Hi all, Another Beta version with (I think) all of the recent suggestions incorporated - well, at least the ones I accepted! I would be grateful for any testing and comments: M23
    1 point
  6. MrCreator, Using simple addition when the author has set suitable values for the various constants is not, IMO, "improper coding", but there we can perhaps agree to differ. And having some "magic numbers" in the UDF follows my long established practice of keeping required include files to a minimum, especially when only a few of the values within them are needed. However, I do like your suggestion of naming the various $iDisplay values - thanks for the suggestion. M23
    1 point
  7. Well, i prefer to code properly to avoid as much as possible those simple mistakes, because we have other places in code where things get complicated. BTW, i would use User Constant in the UDF: Global Enum Step *2 _ $CFF_FLDRTREE = 0, $CFF_FLDRTREENOSUBFLDRS = 1, $CFF_FLDRTREENOFILES = 2, $CFF_NOHIDFILES, _ $CFF_NOSYSFILES, $CFF_SELECTABLE, $CFF_DUPSEL, $CFF_NOFILEEXT, $CFF_SCRLTOFRSTFILE, _ $CFF_SHOWSPLASH, $CFF_RETDEEPONLY, $CFF_DRVLSTRFRSH, $CFF_SHOWICONS And also i suggest to use real constants instead of "magic numbers" inside UDF.
    1 point
  8. Really helpful udf, just was looking for something like that. Just few notes... If $hParent set, you should disable the window. If $hParent Then WinSetState($hParent, '', @SW_DISABLE) EndIf and enable it before GUIDelete: If $hParent Then WinSetState($hParent, '', @SW_ENABLE) EndIf And what about icons for the items? And i suggest to add expansion for checked items (if checkboxes used) that stored in subfolders. I mean when using: _CFF_SetPreCheck($aCheckList, False) _CFF_Choose('Select:', 300, 400, -1, -1, $sRoot, Default, 16, -1, $hParent)
    1 point
  9. As a pending Question to melba I hope you won't mind me bringing up this Question as it isn't directly related to the UDF @OP (not yet anyways) but if you expand the "C:\Users\Public" directory when using kosamja's example posted here it seems impossible to expand folders under that Dir To start i have replaced this line: If Not FileExists($sTreeViewItemPath) Then Return SetError(3, 0, False) With If Not FileExists($sTreeViewItemPath) Then If StringInStr($sTreeViewItemPath, "Public ") Then $sTreeViewItemPath = StringReplace($sTreeViewItemPath, "Public ", "") If Not FileExists($sTreeViewItemPath) Then Return SetError(3, 0, False) EndIf EndIf Which turns those folders to become available as seen but still not expandable yet! As I'm not sure what try next, TIA for any ideas Deye Edit : I wasn't paying attention to whats for it in _AddFolderContentToTreeView() Partly Fixed by replacing: If Not FileExists($sParentTreeViewItemPath) Then Return SetError(2, 0, False) with: If Not FileExists($sParentTreeViewItemPath) Then If StringInStr($sParentTreeViewItemPath, "Public ") Then $sParentTreeViewItemPath = StringReplace($sParentTreeViewItemPath, "Public ", "") If Not FileExists($sParentTreeViewItemPath) Then Return SetError(2, 0, False) EndIf EndIf pending : to rid the extra Public Account Pictures dir Thanks
    1 point
  10. is it possible with ChooseFileFolder to start adding new items immediately after clicking +, like in example in page 15 (https://www.autoitscript.com/forum/topic/125293-choosefilefolder-new-version-16-feb-17/?do=findComment&comment=1431811)? ---------------------------------------------------------------------------------- Edited page 15 example to work without objects, but still too slow... File and Folder TreeView.au3
    1 point
  11. kosamja, That is very impressive code: "Bravo"!!! If it is yours, then would you mind If I looked to see how I might rewrite the UDF to use it. If not, then can you please let me know where you found it so I can ask the author. M23
    1 point
  12. Deye, You do not need my permission to adapt the UDF code - just go right ahead! But I suggest you post any modified code in your own thread and leave this one to my original. I might well pinch some of your changes though! M23
    1 point
  13. Hi Melba, I'm planning on giving this another go, at least till I can make it work with my mods Not that anything is wrong right the way it is now ..for a start, do you think it would be wise to split "_CFF_Choose" from other mods for easier Code implementations\rewrites along the way Or when ever necessary, especially for any user that wants to debug the "_CFF_Choose" part easier \ ly With my current mod I wanted that anything checked as precheck'd right after the GUI is loaded will include also any other newly checks to the final return when "save" is clicked after a refresh was executed at any\some point got really close to getting it done with ideas from the last mod you have posted .. Without concentrating to much (Up for some air till I dive into again) just as an example I use $cRedraw_Dummy case as "refresh", eliminating other $cRedraw_Dummy calls in the script where I couldn't find any use for in my mod And isn't very much different from the original UDF @initial post Edit: will soon be looking for some routine to De-elevate per script, To get any network\mapped drives and re-elevate to get them mapped in ready for any read\write operations Thanks Deye
    1 point
  14. Hi, As xtcislove has not been back to the forum in 6 months (obviously his problem with the UDF not working under x64 was not as pressing as it appeared) has anyone else tested the above Beta code on a x64 machine and can confirm that it works correctly? Grateful for any replies so I can either release a new version or start debugging again! M23
    1 point
  15. xtcislove, Sorry it has taken so long, but I managed to reproduce the effect you were seeing above on another x64 machine and pinpoint the problem - which I believe I have now solved. Here is an amended version of the UDF - can you please test it and see if it solves the problem for you too: ChooseFileFolder_Mod.au3 By the way, this Beta code also contains a whole slew of other amendments which I have been waiting to release - I put them all together to se if they would play nicely once all inserted and so far they do. So do not be alarmed if some things appear a little different - all I am interested in at the moment is getting the UDF to work correctly under x64. M23
    1 point
  16. @Melba23 Any tip for ListViews? Ps: Why should i care? Porn is normal
    1 point
  17. Thanks for the update, thats what i thought but all my experients did not end well but im maybe 6 months into autoit and just getting started with dllstructs. I will keep an eye on this thread to not miss any updates. Best regards
    1 point
  18. Hi Melba23, not 100% sure if this is the thing .. but it very much looks like it to me try : If DllStructGetData($tStruct, "Action") = 2 Or Not _GUICtrlTreeView_GetText($hWndFrom, _GUICtrlTreeView_GetExpanded($hWndFrom, $hItem)) Then GUICtrlSendToDummy($g_cCFF_Expand_Dummy, $hItem) .. Deye
    1 point
  19. xtcislove, I have found the problem - the main struct in the UDF WM_NOIFY handler is not returning the correct data. Now comes the hard part - getting the struct correct! M23
    1 point
  20. xtcislove, Something like this was brought up once, but I never got to the bottom of it as I did not have an x64 machine on which to test. Plus the reporting member was banned soon afterwards and others could run the code without problem. I have just tried the code on my x64 laptop and I get a similar problem - either no subfolders/files or several iterations of them! I will investigate further - it certainly is linked to the #AutoIt3Wrapper_UseX64=y directive as it works fine without it. M23
    1 point
  21. xtcislove, I gave up on that download when it hit 20Mb! Just post the AutoIt code as explained here. M23
    1 point
  22. Okay, that's a bit sad, but understandable. Thanks again for all the great code you've provided. Have a nice weekend Slevin
    1 point
  23. SlevinKT, Welcome to the AutoIt forums. Glad you find my code useful. But I am afraid I am not going to implement icons in this UDF as I believe it would seriously slow the main expansion algorithm. Sorry. M23
    1 point
  24. Deye, Sorry, I did realise that you had posted code above (which I have still not inspected) - here is my Beta which uses the __CFF_Refresh function called programmatically to toggle a "discard/retain existing selection during refresh" flag, while still allowing the same function to be called via a HotKey for the actual refresh (I must say I am quite pleased with that little trick!): And a new example script showing the function in action - just check the console to see whether the items will be retained or discarded during the refresh: #include <GUIConstantsEx.au3> #include <MsgBoxConstants.au3> #include "ChooseFileFolder_Deye.au3" ; Set HotKey (Ctrl-R) for refresh HotKeySet("^r", "_CFF_Refresh") _CFF_RegMsg() $vRet = _CFF_Refresh(1) ConsoleWrite("Retain: " & $vRet & @CRLF) ; Basic _Choose dialog $sRet = _CFF_Choose ("Basic Test", 1, 1, -1, -1, "", "", 0, 50) ConsoleWrite($sRet & " - " & @error & " - " & @extended & @CRLF) $vRet = _CFF_Refresh(0) ConsoleWrite("Retain: " & $vRet & @CRLF) ; Combo _Choose dialog $sRet = _CFF_Choose ("Combo Test", 1, 1, -1, -1, "||c", "", 0, 50) ConsoleWrite($sRet & " - " & @error & " - " & @extended & @CRLF) $vRet = _CFF_Refresh(1) ConsoleWrite("Retain: " & $vRet & @CRLF) ; Checkbox _Choose dialog $sRet = _CFF_Choose ("Checkbox Test", 1, 1, -1, -1, "", "", 0, -1) ConsoleWrite($sRet & " - " & @error & " - " & @extended & @CRLF) $vRet = _CFF_Refresh(0) ConsoleWrite("Retain: " & $vRet & @CRLF) ; Create GUI for _Embed test $hGUI = GUICreate("Embed Test", 500, 500) $cTreeView = GUICtrlCreateTreeView(10, 10, 200, 200) $cReturn = GUICtrlCreateButton("Return", 400, 10, 80, 30) $cList = GUICtrlCreateList("", 10, 300, 200, 150) $cRefresh = GUICtrlCreateDummy() GUISetState() ; _Embed $sRet = _CFF_Embed ($cTreeView, "", "*", 0, $cReturn, $cList, $cRefresh) ConsoleWrite($sRet & " - " & @error & " - " & @extended & @CRLF) $vRet = _CFF_Refresh(1) ConsoleWrite("Retain: " & $vRet & @CRLF) $sRet = _CFF_Embed ($cTreeView, "", "*", 0, $cReturn, $cList, $cRefresh) ConsoleWrite($sRet & " - " & @error & " - " & @extended & @CRLF) Let me know what you think. And please take note of this warning in the __CFF_Refresh header: ; NOTE: When using Ctrl-Return the CTRL key MUST be kept pressed until the refresh splash screen appears ; This is particularly true when treeview checkboxes are enabled I found that the added code was slowing the UDF when new branches were being filled and if I actioned a Ctrl-"Return" refresh immediately there was a possibility of the button event happening after a short delay, with the result that the Ctrl key was no longer pressed at that point - and so the UDF assumed that I wanted to "Return" and promptly did so! M23
    1 point
  25. Hi Melba, It works well, this only needs a small procedure to sustain the state of checks just like what $g_aCFF_PreCheckRetain is for when reloading the function Wasted 2 ours looking at the UDF I tried a few things like ways to remove stale references to $sAddFile_List and Such but soon was getting some hunch that the TreeView may not Or can't be updated in such ways .. .. back with my half baked thoughts .. will try again when i get a moment Thanks again Deye
    1 point
  26. Deye, Have a play with this Beta and see what you think: A quick example script - either press the "Return" button with Ctrl pressed or use the HotKey to refresh the drives available: As I anticipated, you will lose any previously selected items, which I feel is reasonable as you could be refreshing the tree and now no longer have access to certain drives. Let me know what you think - and comments from others are always welcome too. M23
    1 point
  27. Melba, I think that will just be good enough for what I need As you already suggested it may not be all possible to keep the list intact while adding - removing Root folders .. at least Not by a quick fix (for now.. ) Thanks
    1 point
  28. Deye, So basically a _CFF_Refresh function. I think I can see how it might be done, but you would almost certainly lose all previously selected items - would that be a problem? M23
    1 point
  29. Hi Melba, I'm looking for a way to be able to update the "choose list" on the fly at my own trigger That will act as a refresh to the list for any drive letters (newly available) or removed, (redrawn back to the GUI) Without needing to close\restart the _CFF_Choose() function I tried a few things without a desired outcome .. Maybe you can devise something for this if not too busy Thanks Deye
    1 point
  30. m00, Sorry it took so long - a serious family illness and a new grandson got in the way! Here is a new Beta of the UDF with the freezing _Embed bug fixed and a rather better-working ability to select both folders and files when required. There is a small change in both _Choose and _Embed functions - $iDisplay option 3 has been removed as the new logic means that is was identical to option 2. The new options work as follows: Option Display Selectable Action when folder double-clicked 0 Folders and files Files only Folder expands/contracts 1 Files only Files only N/A 2 Folders only Folders only Selects folder +16 Folders and files Folders and files Selects folder only when using option 0 There is also one small change for consistency: pressing the {ENTER} key when in single selection mode now selects the highlighted (highlit?) item in both _Choose and _Embed - it did not do so in _Choose before. Please test it and let me know if you like it - and of course anyone else is free to test and comment as well. M23
    1 point
  31. Thank you. I am now trying to show only folders (with their parents) that contain .jpg files. Also, I would like folders that contain .jpg files to be emphasized: preferably in color, or bolded. Is this possible with ChooseFileFolder? Here is my code: _CFF_Choose('Jpeg dirs on H: drive',Default,Default,Default,Default,'h:','*.jpg||$RECYCLE.BIN',2) Your expand when needed makes a big difference!
    1 point
  32. c.haslam, Just use the Exclude_Folders section of the $sMask parameter - something like this: $sRet = _CFF_Choose("Select a file", 300, 500, Default, Default, "M:\", "*.*||$RECYCLE.BIN") This is explained in the _CFF_Choose function header. There are always worth a read when the UDF author has gone to the trouble to write them! M23
    1 point
  33. Apzo

    SQLite3 on WIndows 10

    This one worked for me: http://www.sqlite.org/2016/sqlite-dll-win32-x86-3110100.zip should be the good one. Regards, Apzo.
    1 point
  34. Nikolas92, Good to hear - but it should not make a difference so I will still take a look once at the code once I get a moment to myself after our houseguests have gone. M23
    1 point
  35. solved my problem, GUICtrlCreateTreeView was causing it. if _GUICtrlTreeView_Create is used instead then it works correctly.
    1 point
  36. I tested it with example 8 from Example File 1 on windows 10 enterprise x64 (default settings). I compiled script for 64 bit. #NoTrayIcon #RequireAdmin #include "ChooseFileFolder.au3" Local $sRet, $aRet ; Register handlers $sRet = _CFF_RegMsg() If Not $sRet Then MsgBox(16, "Failure!", "Handler not registered") Exit EndIf ; Choose multiple files/folders using checkboxes - all checked items returned $sRet = _CFF_Choose("Ex 8 - Multiple checkboxes", 300, 500, -1, -1, "", Default, 0 + 16, -1) If $sRet Then $aRet = StringSplit($sRet, "|") $sRet = "" For $i = 1 To $aRet[0] $sRet &= $aRet[$i] & @CRLF Next MsgBox(0, "Ex 8 - Multiple checkboxes", "Selected:" & @CRLF & @CRLF & $sRet) Else MsgBox(0, "Ex 8", "No Selection") EndIf
    1 point
  37. nobbitry, Thanks for that. Nikolas92, Can you let me see the line you used to call the UDF - perhaps you made a small syntax error resulting in the limited dispay. M23
    1 point
  38. Hi, Thanks it's just what i'm looking for !! I added some details in it : - Press "Enter" to close the editbox - Editbox follow the listview when you change its position. #include <GuiConstants.au3> #include <GuiEdit.au3> #include <GuiListView.au3> #include <WindowsConstants.au3> #include <EditConstants.au3> #include <WinAPI.au3> Opt("GuiCloseOnESC", 0) Global $hEdit, $hDC, $hBrush, $Item = -1, $SubItem = 0 Global $Style = BitOR($WS_CHILD, $WS_VISIBLE, $ES_AUTOHSCROLL, $ES_LEFT) $hGUI = GUICreate("ListView Subitems edit in place", 370, 280) $hNM_DBCLK = GUICtrlCreateDummy() $hEN_KILLFOCUS = GUICtrlCreateDummy() $hListView = _GUICtrlListView_Create($hGUI, "test1|test2", 32, 35, 300, 214) _GUICtrlListView_SetExtendedListViewStyle($hListView, BitOR($LVS_AUTOARRANGE,$LVS_EX_FULLROWSELECT,$LVS_EX_DOUBLEBUFFER,$LVS_EX_SUBITEMIMAGES)) For $i = 1 To 10 _GUICtrlListView_AddItem($hListView, "Item " & $i) _GUICtrlListView_AddSubItem($hListView, $i - 1, "SubItem " & $i, 1) Next GUIRegisterMsg($WM_NOTIFY, "WM_NOTIFY") GUIRegisterMsg($WM_COMMAND, "WM_COMMAND") GUISetState() While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE Exit case $hNM_DBCLK Start_EditingLV() Case $hEN_KILLFOCUS End_EditingLV() EndSwitch WEnd Func WM_NOTIFY($hWnd, $iMsg, $iwParam, $ilParam) Local $tNMHDR, $hWndFrom, $iCode $tNMHDR = DllStructCreate($tagNMHDR, $ilParam) $hWndFrom = DllStructGetData($tNMHDR, "hWndFrom") $iCode = DllStructGetData($tNMHDR, "Code") Switch $hWndFrom Case $hListView Switch $iCode Case $NM_DBLCLK GUICtrlSendToDummy($hNM_DBCLK) EndSwitch EndSwitch Return $GUI_RUNDEFMSG EndFunc Func FrameRect($hDC, $nLeft, $nTop, $nRight, $nBottom, $hBrush) Local $stRect = DllStructCreate("int;int;int;int") DllStructSetData($stRect, 1, $nLeft) DllStructSetData($stRect, 2, $nTop) DllStructSetData($stRect, 3, $nRight) DllStructSetData($stRect, 4, $nBottom) DllCall("user32.dll", "int", "FrameRect", "hwnd", $hDC, "ptr", DllStructGetPtr($stRect), "hwnd", $hBrush) EndFunc Func WM_COMMAND($hWnd, $Msg, $wParam, $lParam) Local $iCode = BitShift($wParam, 16) Switch $lParam Case $hEdit Switch $iCode Case $EN_KILLFOCUS GUICtrlSendToDummy($hEN_KILLFOCUS) EndSwitch EndSwitch Return $GUI_RUNDEFMSG EndFunc Func Start_EditingLV() ControlDisable($hGUI, "", HWnd(_GUICtrlListView_GetHeader($hListView))) Local $aHit = _GUICtrlListView_SubItemHitTest($hListView) Local $hRect = ControlGetPos($hGUI, "", $hListView) If ($aHit[0] <> -1) And ($aHit[1] = 0) Then $Item = $aHit[0] $SubItem = 0 Local $aRect = _GUICtrlListView_GetItemRect($hListView, $Item) ElseIf ($aHit[0] <> -1) And ($aHit[1] > 0) Then $Item = $aHit[0] $SubItem = $aHit[1] Local $aRect = _GUICtrlListView_GetSubItemRect($hListView, $Item, $SubItem) Else Return $GUI_RUNDEFMSG EndIf Local $iItemText = _GUICtrlListView_GetItemText($hListView, $Item, $SubItem) Local $iLen = _GUICtrlListView_GetStringWidth($hListView, $iItemText) $hEdit = _GUICtrlEdit_Create($hGUI, $iItemText, $aRect[0] + ($hRect[0] + 3), $aRect[1] + $hRect[1], $iLen + 10, 17, $Style) _GUICtrlEdit_SetSel($hEdit, 0, -1) _WinAPI_SetFocus($hEdit) $hDC = _WinAPI_GetWindowDC($hEdit) $hBrush = _WinAPI_CreateSolidBrush(0x0000FF) FrameRect($hDC, 0,0, $iLen + 10 , 17, $hBrush) HotKeySet("{ENTER}", "End_EditingLV") EndFunc Func End_EditingLV() Local $iText = _GUICtrlEdit_GetText($hEdit) _GUICtrlListView_SetItemText($hListView, $Item, $iText, $SubItem) _WinAPI_DeleteObject($hBrush) _WinAPI_ReleaseDC($hEdit, $hDC) _WinAPI_DestroyWindow($hEdit) ControlEnable($hGUI, "", HWnd(_GUICtrlListView_GetHeader($hListView))) $Item = -1 $SubItem = 0 HotKeySet("{ENTER}") EndFunc I know this post is old but maybe this can help anyone.
    1 point
  39. Ascend4nt and Yashied, Thank you both for your efforts. I mentioned a tutorial on this x64 compatability problem to enlighten hobbyist coders like me the last time it came up - I suppose both of you are still not interested in writing one? New UDF and example in the first post. M23
    1 point
  40. Yes, you are right, this is an alignments problem under x64 (). But the Melba23's problem in this case in the following. "int IDFrom" instead of "uint_ptr IDFrom". Thanks for the links.
    1 point
  41. Yes of course, I wanted to say a double word.
    1 point
  42. guinness, Thanks for that. I have no other reports of the GUIFrames UDF not being x64 compatible after Yashied helped me fix it. The size of drive has nothing to do with it - it is a simple case of the treeview not being created as a result of GUIFrames failing to create the frame! So as the error is most certainly coming from that UDF (and the fact that UEZ cannot run that UDF on x64) I am wondering what is different with UEZ's machine. M23 Edit: Typnig.
    1 point
  43. UEZ, Interesting. With some help from Yashied I thought the GUIFrame UDF was x64 compatible. - see here and the next few posts. M23
    1 point
  44. UEZ, It looks like the problem is in the GUIFrame UDF not this one, as you only have a problem when $fSingleSel = False. In that case, the UDF creates a treeview within a frame created by GUIFrame and this is obviously not happening. Have you tried to run the GUIFrame UDF and its examples - if not could you please do do? I wonder if there is a problem with it on x64 systems - it uses many DllCalls so I would not be at all surprised. M23
    1 point
  45. I get an error on example 6 when I select my C drive -> Line 419 (File "C:\Coding\AU3\GUI\ChooseFileFolder\ChooseFileFolder.au3"): $hTreeView = GUICtrlCreateTreeView(0, 0, $iW - 20, $aTV_Pos[3]) $hTreeView = GUICtrlCreateTreeView(0, 0, $iW - 20, $aTV_Pos^ ERROR Error: Subscript used with non-Array variable. Btw, nice coding! Br, UEZ
    1 point
  46. You need #include <Process.au3> with _RunDos ShutDown(1) But anyway, here's the code: ;If you press the END key, the AntiIdle stops HotKeySet("{END}", "EndAntiIdle") While 1 Run(@ComSpec & " /c @echo hello","", @SW_HIDE) Sleep(600000) WEnd ;Runs the check every 600000 seconds (10 minutes) Func EndAntiIdle() Exit 0 EndFunc
    1 point
×
×
  • Create New...