It has been a while since I last installed and used Autoit, I just installed the latest version along with Scite. For some reason, I do not have the option to create new .au3 files when right clicking. I have tried rebooting, and running the installation as administrator as mentioned in other threads. no joy...
OS = Windows 10 Enterprise version 1806
Thanks in advance!
ICU - Icon Configuration Utility
Current Version: v6 (2018-Sep-16)
Restore your desktop when the icons get "rearranged".
Melba23 and I found we were working on very similar ideas to restore the Desktop icons to their normal place if they became "rearranged" (
). Vista seems to like this doing on occasion just for fun - but we all know some apps and games which change the display resolution or move icons around. This annoys "tidy" people who like their desktops arranged "just so" - I am particularly thinking of this desktop when I say that!
We combined efforts and here is the result of our labors.
Operation is easy - press "Save" to store a particular configuration and "Restore" to reset the icons to the saved positions in the selected configuration file. "Delete" allows you to remove unwanted configuration files from the list. There is a command line option so that the restoration can be run via HotKeys if required (that is why the script warns that it should be compiled for full functionality). You can decide what to do with any icons that have been added since you last saved the configuration file - the default is to put them in the top-left corner, but you can also banish them way off-screen or, more sensibly, specify a location for them.
A new feature as of ICU v3.4 is the optional Desktop Contextmenu Integration (DCI) for Win7 (Win7 only because Microsoft implemented an easy way to do this through the registry as of this release).
Version 3.3 should fix the empty save file bug
Version 3.4 Win7: Admin rights no longer needed for DCI
Version 5.0 Win8 compatibility for DCI
The source and executable can be downloaded from my site: http://www.funk.eu
Kudos to Ascend4nt, Melba23, Prog@ndy, & Valik for parts of the code.
Please let me know if you found some piece of code in the source for which I forgot to mention a credit.
Enjoy, let me know what you think of ICU and with Best Regards
I had written a GUI with several buttons and I wanted one of the buttons to show its context menu regardless of the user right or left clicking the button. The whole purpose of the button was to show the user a menu of options and a context menu fit the need just fine, but I needed it to display with either click option. I came up with the code below to accomplish this but I feel like I might be missing some very obvious easier way to do this and I feel it's a little lame to be forcing a right click mouse action on the button as a result of the user doing a left click, but it works!
Anyone have a suggestion of a better way to do this? Otherwise, if this idea helps you, here you go.
#include <GUIConstantsEx.au3> LeftClickContextTest() Func LeftClickContextTest() Local $hGUI = GUICreate("My GUI", 200, 100) Local $button = GUICtrlCreateButton("Show Context", 15, 40, 85, 25) Local $close = GUICtrlCreateButton("Close", 110, 40, 85, 25) Local $context = GUICtrlCreateContextMenu($button) GUICtrlCreateMenuItem("Test Context Item 1", $context) GUICtrlCreateMenuItem("Test Context Item 2", $context) GUICtrlCreateMenuItem("Test Context Item 3", $context) GUISetState(@SW_SHOW, $hGUI) While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE, $close ExitLoop Case $button MouseClick("right", MouseGetPos(0), MouseGetPos(1), 1, 0) EndSwitch WEnd EndFunc
I am trying to create a script to clean up users' desktops by moving all desktop folders and files (except the two hidden "desktop.ini" files and a MyDesktop.lnk shortcut) to a different folder. The script below will move files but not folders. The other issue with the script is that it doesn't seem to execute from a location other than the user's desktop. I would appreciate any suggestions.
#include <File.au3> MsgBox(64, "Desktop", "Cleaning up Desktop. This box will close in 4 seconds.", 4) $Files = _FileListToArray(@DesktopDir,"*",1) For $Index = 1 To $Files If StringRight($Files[$Index],4) <> ".ini, MyDesktop.lnk" Then FileMove($Files[$Index],'F:\HOME\Desktop') EndIf Next