Leaderboard
Popular Content
Showing content with the highest reputation on 02/15/2025 in all areas
-
Another AutoIt extension for Visual Studio Code
seadoggie01 reacted to genius257 for a topic
Version 1.8.2 has just been released! I should have been 1.8.0, but issues with deployment pipeline after bigger changes to how the parser code and types are generated (internally) meant that i had to increment patch version 2 times, to successfully be able to release to the extension marketplaces. Notable changes: Added au3 DocBlock `@link` tag support Added syntax highlighting for au3 DocBlock and legacy UDF headers 2 things i would like feedback on, if possible: About the new syntax highlighting: Let me know if and/or how you like or dislike it. Performance: small changes to how the parser worked with some parser rules, to better generate types. Smaller tests indicated it was same or faster, but it can very much depend how it traverses through the code. Let me know if you notice any slow down, so I can look into fixing it ASAP! Feedback can be here, via an issue or via the discussion for the release.1 point -
Uploaded a new beta installer that has the following updates: Added VSCode wrapper to show output in user tasks Added example user tasks Fixed some /AddIncludes issues with constants and duplicate local includes Just take a look at the tasks.json included in the autoit3Wrapper directory, which will allow you to add AutoIt3Wrapper tasks like /addincludes and /au3stripper to the tasks in VScode. These tasks will shell an already included powershell script (see below) in the AutoIt3Wrapper directory that will ensure that the output will be shown in the VScode terminal window. The powershell wrapper included with some more detailed description: # # # # powershell script to wrap AutoIt3Wrapper to use in VSCODE and show the console output when ran as Task # # # When you get: File C:\Program Files (x86)\AutoIt3\SciTE\run_autoit.ps1 cannot be loaded # because running scripts is disabled on this system. For more information...... # The error message indicates that PowerShell script execution is disabled on your system. # You need to enable script execution by setting the execution policy. # You can do this by # 1. running PowerShell as an administrator and executing the following command: # 2. Do command: Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser # This command sets the execution policy to RemoteSigned for the current user, allowing locally created scripts to run. param ( [string]$AutoitPath, [string]$Options, [string]$ScriptFile ) # Run AutoIt3 Wrapper & "$autoitPath\Autoit3.exe" "$autoitPath\Scite\AutoIt3Wrapper\AutoIt3Wrapper.au3" $options /in "$scriptfile" | Write-Output echo "--Done--" Thoughts?1 point
-
ListView group header alignment
pixelsearch reacted to ahmet for a topic
1 point -
ListView group header alignment
argumentum reacted to pixelsearch for a topic
@argumentum thanks for the test1 point -
ListView group header alignment
pixelsearch reacted to argumentum for a topic
Yes. Win11. #include <GUIConstantsEx.au3> #include <GuiImageList.au3> #include <GuiListView.au3> #include <MsgBoxConstants.au3> Example() Func Example() Local $hGui = GUICreate("ListView Get/Set Group Info (v" & @AutoItVersion & ")", 400, 300) WinSetOnTop($hGui, "", 1) Local $idListview = GUICtrlCreateListView("", 2, 2, 394, 268) GUISetState(@SW_SHOW) ; Set ANSI format ;~ _GUICtrlListView_SetUnicodeFormat($idListview, False) ; Load images Local $hImage = _GUIImageList_Create() _GUIImageList_Add($hImage, _GUICtrlListView_CreateSolidBitMap($idListview, 0xFF0000, 16, 16)) _GUIImageList_Add($hImage, _GUICtrlListView_CreateSolidBitMap($idListview, 0x00FF00, 16, 16)) _GUIImageList_Add($hImage, _GUICtrlListView_CreateSolidBitMap($idListview, 0x0000FF, 16, 16)) _GUICtrlListView_SetImageList($idListview, $hImage, 1) ; Add columns _GUICtrlListView_AddColumn($idListview, "Column 0", 100) _GUICtrlListView_AddColumn($idListview, "Column 1", 100) _GUICtrlListView_AddColumn($idListview, "Column 2", 100) ; Add items _GUICtrlListView_AddItem($idListview, "Row 0: Col 0", 0) _GUICtrlListView_AddSubItem($idListview, 0, "Row 0: Col 1", 1) _GUICtrlListView_AddSubItem($idListview, 0, "Row 0: Col 2", 2) _GUICtrlListView_AddItem($idListview, "Row 1: Col 0", 1) _GUICtrlListView_AddSubItem($idListview, 1, "Row 1: Col 1", 1) _GUICtrlListView_AddItem($idListview, "Row 2: Col 0", 2) ; Build groups _GUICtrlListView_EnableGroupView($idListview) _GUICtrlListView_InsertGroup($idListview, -1, 1, "Group 1", 1) _GUICtrlListView_InsertGroup($idListview, -1, 2, "Group 2") _GUICtrlListView_SetItemGroupID($idListview, 0, 1) _GUICtrlListView_SetItemGroupID($idListview, 1, 2) _GUICtrlListView_SetItemGroupID($idListview, 2, 2) ; Change group information Local $aInfo = _GUICtrlListView_GetGroupInfo($idListview, 1) ;~ MsgBox($MB_SYSTEMMODAL, "Information", "Group 1 Text: " & $aInfo[0]) ;~ _GUICtrlListView_SetGroupInfo($idListview, 1, "New Group 1") ;~ _GUICtrlListView_SetGroupInfo($idListview, 1, "New Group 1", 0) ; left ;~ _GUICtrlListView_SetGroupInfo($idListview, 1, "New Group 1", 1) ; center _GUICtrlListView_SetGroupInfo($idListview, 1, "New Group 1", 2) ; right ; Loop until the user exits. Do Until GUIGetMsg() = $GUI_EVENT_CLOSE GUIDelete() EndFunc ;==>Example1 point -
Strange behaviour (file deleted) with FileCopy ()
argumentum reacted to Jemboy for a topic
I have created an example script to illustrate the problem. The script basically does the following: make a backup of "C:\Windows\SystemResources\mstscax.dll.mun" adjust the permissions so that 'mstscax.dll.mun' can be overwritten and overwrite 'mstscax.dll.mun' restore the initial situation (file and permissions) At point 2, 'mstscax.dll.mun' disappears from the folder "C:\Windows\SystemResources" when I use FileCopy(). If I replace FileCopy() with DOS Copy (see remarked line) then 'mstscax.dll.mun' is overwritten and does not disappear! Note: if the script does not execute properly (e.g. stopped prematurely), 'mstscax.dll.mun' can be lost or the original situation will not be restored. #RequireAdmin #Region ;**** Directives created by AutoIt3Wrapper_GUI **** #AutoIt3Wrapper_UseX64=y #EndRegion ;**** Directives created by AutoIt3Wrapper_GUI **** #include <File.au3> $sTitle ="FileCopyTest v1.0" $Answer = MsgBox($MB_ICONQUESTION + $mb_topmost + $MB_YESNO,$sTitle,"This script might make irreversible changes to your computer!" & @CRLF & "Do you want to continue ?") If $Answer<>$IDYES then Exit $sTempFolder = _TempFile(@TempDir, "TempFolder_", "") ; Create a unique temporary folder name $ResFC1 = FileCopy ("C:\Windows\SystemResources\mstscax.dll.mun", $sTempFolder & "\" & "mstscax.dll.mun", $FC_OVERWRITE + $FC_CREATEPATH) MsgBox ($mb_topmost,$sTitle,"Just backupped 'mstscax.dll.mun' to " & $sTempFolder & "." & @CRLF & "FileCopy Result: " & $ResFC1) ;Takeover rights, set permission to administrators and copy 'mstscax.dll.mun' back over it self. RunWait(@ComSpec & " /c " & 'takeown /f "C:\Windows\SystemResources\mstscax.dll.mun" /a', "", @SW_HIDE) RunWait(@ComSpec & " /c " & 'icacls "C:\Windows\SystemResources\mstscax.dll.mun" /grant Administrators:F', "", @SW_HIDE) $ResFC2 = FileCopy ($sTempFolder & "\" & "mstscax.dll.mun", "C:\Windows\SystemResources\mstscax.dll.mun", $FC_OVERWRITE) ;$ResFC2 = RunWait(@ComSpec & ' /c COPY "' & $sTempFolder & "\" & "mstscax.dll.mun" & '" "' & "C:\Windows\SystemResources\mstscax.dll.mun" & '" /Y', "", @SW_HIDE) ; THIS copy works unlike FileCopy ShellExecute("C:\Windows\SystemResources") MsgBox ($mb_topmost,$sTitle,"Overwrit backupped 'mstscax.dll.mun' to original location." & @CRLF & "The file 'mstscax.dll.mun' has disappeared!" & @CRLF & "FileCopy Result: " & $ResFC2) ;Change folder rights to repair missing DLL and restore all rights RunWait(@ComSpec & " /c " & 'takeown /f "C:\Windows\SystemResources" /a', "", @SW_HIDE) RunWait(@ComSpec & " /c " & 'icacls "C:\Windows\SystemResources" /grant Administrators:F', "", @SW_HIDE) $ResFC3 = FileCopy ($sTempFolder & "\" & "mstscax.dll.mun", "C:\Windows\SystemResources\mstscax.dll.mun", $FC_OVERWRITE) RunWait(@ComSpec & " /c " & 'icacls "C:\Windows\SystemResources\mstscax.dll.mun" /setowner "NT SERVICE\TrustedInstaller" /C', "", @SW_HIDE) RunWait(@ComSpec & " /c " & 'icacls "C:\Windows\SystemResources\mstscax.dll.mun" /grant:r Administrators:RX', "", @SW_HIDE) RunWait(@ComSpec & " /c " & 'icacls "C:\Windows\SystemResources" /setowner "NT SERVICE\TrustedInstaller" /C', "", @SW_HIDE) RunWait(@ComSpec & " /c " & 'icacls "C:\Windows\SystemResources" /grant:r Administrators:RX', "", @SW_HIDE) DirRemove ($sTempFolder,$DIR_REMOVE) MsgBox ($mb_topmost,$sTitle,"Restored 'C:\Windows\SystemResources\mstscax.dll.mun' and" & @CRLF & "Restored all to original state." & @CRLF & "FileCopy Result: " & $ResFC3)1 point -
So basically you ask a human to solve a machine issue asked by another human. Instead of having this other human solves his own issue. I do not think I will help you for now on (ever).1 point