Leaderboard
Popular Content
Showing content with the highest reputation on 09/17/2020 in all areas
-
This is one of the most stupidest post ik have ever seen here... And I've seen a lot You probably have no idea why I said this until you figure it out somehow.2 points
-
You should go back and research how AHK got its start.2 points
-
Hello!!! In the past I had problems adding an application as a default for an extension in Windows 10. (It was easy in windows 7 using Registry) But since Windows 8 It requires to do some steps more. I wrote a tool (in other programming language) months ago for handling it. But now I just want to share an AutoIt version. Check on GitHub. Saludos1 point
-
glad to help š1 point
-
AutoIt Snippets
pixelsearch reacted to seadoggie01 for a topic
There's a certain grace that comes with admitting you were wrong (or that someone did something better). Trust me, I've been there... too much. It happens a lot, don't worry about it.1 point -
Clicking on button in GUICtrlInput not doing anything
TheCrimsonCrusader reacted to mikell for a topic
Although mixing both modes is not recommended, It is possible by disabling/enabling OnEventMode before/after using MessageLoop mode But as said Zedna using only one is a much better practice #include <GuiConstants.au3> Opt("GUIOnEventMode", 1) $GUI = GUICreate("Test GUI",400,100,-1,-1,BitOR($WS_POPUP, $WS_DLGFRAME, $WS_EX_TOPMOST), 0) WinSetOnTop ($GUI, "",1) $UNLOCK_BITLOCKER = GUICtrlCreateButton("Unlock BitLocker", 20, 20, 200, 25) GUICtrlSetOnEvent($UNLOCK_BITLOCKER,"UNLOCK_BITLOCKER_FUNCTION") GUISetState() While 1 Sleep(1000) WEnd Func UNLOCK_BITLOCKER_FUNCTION() Opt("GUIOnEventMode", 0) GUICreate("Microsoft BitLocker",720, 165, -1,-1,BitOR($WS_DLGFRAME, $WS_EX_TOPMOST), 0) WinSetOnTop ("Microsoft BitLocker", "",1) GUICtrlCreateLabel("Please enter the BitLocker recovery key and then click on the OK button:",10,10,700,35) GUICtrlSetFont (-1,-1, 800) $BitLockerRecoveryKey = GUICtrlCreateInput("", 10, 50, 700, 35) $idBtn = GUICtrlCreateButton("OK", 10, 100, 160, 35) GUISetState(@SW_SHOW) While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE ExitLoop Case $idBtn ExitLoop EndSwitch WEnd $BitLockerRecoveryKey2= GUICtrlRead($BitLockerRecoveryKey) $ReturnCode = RunWait("cmd.exe /c manage-bde -unlock c: -recoverypassword " & $BitLockerRecoveryKey2,"",@SW_HIDE) If $ReturnCode = "0" then MsgBox(262208,"Microsoft BitLocker","The BitLocker recovery volume is now unlocked.") Else MsgBox(262160,"Microsoft BitLocker","An invalid BitLocker recovery key was specified. Please try again.") EndIf GUIDelete("Microsoft BitLocker") Return Opt("GUIOnEventMode", 1) EndFunc1 point -
My solution works for all users. therefore, a #RequireAdmin is needed.1 point
-
small update in GitHub related to1 point
-
Set Windows 10 Default Application
argumentum reacted to Danyfirex for a topic
@WilliamasKumeliukas about browser I know how to do it. I started doing a code for it time ago but didn't finish it. Maybe I get inspired again and finish it. Saludos1 point -
Set Windows 10 Default Application
Danyfirex reacted to WilliamasKumeliukas for a topic
Hello @Danyfirex, I must say your UDF will be very useful in my project I had in mind to modify in [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\] .pdf and .pdfxml but I didnt test it. Anyways, Nice UDF! your udf will make it much simplier , I will make sure to mention you in my project post and script. EDIT 1 Do you know how to change default browser by any miracle? Thank you, ~WilliamasKumeliukas1 point -
Whatever way is the most suitable to use, this should always be done anyway, as it is THE best coding practice1 point
-
Simpler: ; Returns the string on the left side of a search string consisting of digits only ConsoleWrite(_StringGetDigitLeft("1234abcd5678") & @CRLF) ; Results in "1234" ConsoleWrite(_StringGetDigitLeft("abcd5678") & @CRLF) ; Results in "" ; Returns the string on the right side of a search string consisting of digits only ConsoleWrite(_StringGetDigitRight("1234abcd5678") & @CRLF) ; Results in "5678" ConsoleWrite(_StringGetDigitRight("1234abcd") & @CRLF) ; Results in "" Func _StringGetDigitLeft(Const ByRef $sString) ; Return String(Number($sString)) ; requires at least one leading digit Return StringRegExpReplace($sString, "^(?|(\d+)|())(.*$)", "$1") EndFunc Func _StringGetDigitRight(Const ByRef $sString) Return StringRegExpReplace($sString, "(.*?)(?|(\d+)|())$", "$2") EndFunc1 point
-
Updated. No according with @mLipok's suggestions because I want to keep main file name due to the main tool I wrote is SFTA so I want to keep it related, and the main function was renamed similar to my PowerShell version (Set-FTA) so now It's _Set_FTA. I'll consider an update to rename all according to our best practices, but for now it will stay that way. Saludos1 point
-
A faster way to display buttons, text and progress bars in a scrollable grid?
Laurynelis reacted to Melba23 for a topic
Laurynelis, My GUIListViewEx UDF (link is in my sig) allows you to expand the functionality of ListViews considerably. You can have coloured items, editable items, run user functions on item selection, etc. Take a look and see if it might be of use - I would be happy to help get it integrated into your app if you decide to go that route. M231 point -
i'm slightly confused. there are "default programs", occasionally referred to as "default apps", which are used to handle common tasks, such as web browsing, map navigation, email, etc. and there is file type association, which is used to assign a specific file type with a specific program. these are not the same thing, this kind-of explains it. this UDF handles file type association, but the topic title seems to refer to the default applications. i believe some clarification is required here. secondly, this UDF sets file type association for the current user only. what would be the process for all users? would switching HKCU to HKLM suffice (with admin rights in effect, of course)?1 point
-
Siwa, I can see the problem. It looks to me as if you have too many controls in the GUI and Windows/AutoIt cannot keep up with scrolling that many - particularly as so many of them are graphic controls (28 per element) which are notoriously resource heavy. My suspicions seem to be confirmed by the fact that if I reduce the size of the $Names array to around 10 then the GUI scrolls without problem - as is the case if I remove all the graphic controls. I suggest you try to simplify the the GUI - for example as each element is identical, do you need ALL the controls for each one? Can you not have a simple scrollable list of the elements pulled from the Excel sheet and then a separate section to hold a single instance of the all the complicated controls which will only affect the selected element? M231 point
-
Siwa, The problem is very obviously in line #3245. ... But if you post your code I might well be able to offer some sensible help. M231 point
-
Hello guys, @mLipok as @argumentum says it's just an array. I've updated the script according your suggestions. Thank you both Saludos1 point
-
Showing Unknown Function name while accessing Array element
harshal984 reacted to TheXman for a topic
Variable names in AutoIt start with a "$".1 point -
autoitscript for audacity makes my pc fan very loud
asiawatcher reacted to JockoDundee for a topic
though you should get about 2 minutes of relief a day from the loud fan noise, if Iām reading the script right1 point -
Delete Temp Files
Netol reacted to insignia96 for a topic
#Include <File.au3> #Include <Array.au3> $Debug=1 Func EmptyFolder($FolderToDelete) $AllFiles=_FileListToArray($FolderToDelete,"*",0) If $Debug Then ConsoleWrite("-->" & $FolderToDelete & @CRLF ) If IsArray($AllFiles) Then If $Debug Then _ArrayDisplay( $AllFiles,$FolderToDelete) EndIf For $i = 1 To $AllFiles[0] $crt = FileGetTime( $FolderToDelete & "\" & $AllFiles[$i], 1 ) If $crt[2] = @MDAY And $crt[0] = @YEAR And $crt[1] = @MON Then If $Debug Then ConsoleWrite( $FolderToDelete & "\" & $AllFiles[$i] & " --> Today's File, Skipping!" & @CRLF ) EndIf ContinueLoop EndIF $delete = FileDelete($FolderToDelete & "\" & $AllFiles[$i]) If $Debug Then ConsoleWrite($FolderToDelete & "\" & $AllFiles[$i]& " =>"&$delete & @CRLF ) EndIf DirRemove($FolderToDelete & "\" & $AllFiles[$i], 1) Next EndIf EndFunc EmptyFolder (@HomeDrive & @HomePath & "\Local Settings\Temporary Internet Files\Content.IE5") EmptyFolder (@HomeDrive & @HomePath & "\Local Settings\Temporary Internet Files") EmptyFolder (@HomeDrive & @HomePath & "\Cookies") EmptyFolder (@HomeDrive & @HomePath & "\Local Settings\History") EmptyFolder (@HomeDrive & "\Temp\Temporary Internet Files") EmptyFolder (@WindowsDir & "\Temp") EmptyFolder (@HomeDrive & "\Temp") EmptyFolder (@HomeDrive & @HomePath & "\Recent") EmptyFolder (@HomeDrive & @HomePath & "\Application Data\Microsoft\Office\Recent") EmptyFolder (@HomeDrive & @HomePath & "\Local Settings\Temp") ShellExecuteWait("RunDll32.exe"," InetCpl.cpl,ClearMyTracksByProcess 255") That Should do it. I think1 point -
AutoIt Snippets
TheDcoder reacted to DonChunior for a topic
That's a matter of opinion. š I find my variant more comprehensible.0 points -
Hi! Why don't the AutoIt-developer contract in the development of AutoHotKey (https://www.autohotkey.com/) ? Seems they have similar goals. And AHK is OpenSource. So it is easy to contribute there. Btw: Why haven't AutoIt published any code? Is there 3rd party code integrated, so that it isn't possible? Greetings theuserbl0 points