
Valik
-
Posts
18,334 -
Joined
-
Last visited
-
Days Won
87
Reputation Activity
-
Valik got a reaction from 20Ice18 in Create Registry Key
RegWrite automatically creates the key if it doesn't already exist.
-
Valik got a reaction from TheDcoder in DllStruct and Array memory handling?
Sort of not. AutoIt does not have a garbage collector. When an object is goes out of scope it's destroyed, full stop. There is no delayed/deferred/scheduled cleanup. A variable goes out of scope, it's gone. Return values are a special case, obviously.
monoceres said it best. You don't need to worry about memory so stop worrying about it. I find it a little insulting that you think there is even potential we'd overlook such a glaring logic hole there.
-
Valik got a reaction from mLipok in DllStruct and Array memory handling?
Sort of not. AutoIt does not have a garbage collector. When an object is goes out of scope it's destroyed, full stop. There is no delayed/deferred/scheduled cleanup. A variable goes out of scope, it's gone. Return values are a special case, obviously.
monoceres said it best. You don't need to worry about memory so stop worrying about it. I find it a little insulting that you think there is even potential we'd overlook such a glaring logic hole there.
-
Valik got a reaction from TheDcoder in A set of question for file
If there was a hot blonde "cleaning" under my desk there would not only be no documentation, there'd be no features, either.
-
Valik got a reaction from pixelsearch in $GUI_EVENT_PRIMARYDOWN
A second event can not be fired while still within the callback function for the first event. So if your OnPrimaryDown callback is running a loop, you're right, your OnPrimaryUp callback will not be invoked. You can avoid this by setting a flag in OnPrimaryDown and un-setting that flag in OnPrimaryUp. Then in your While loop that keeps the script active, check the condition of the flag. If the flag is down, execute what you need to do while the mouse button is down and poll the flag until it's unset denoting the OnPrimaryUp event fired.
-
Valik got a reaction from Professor_Bernd in Variable name -> String?
That may be true, but the key difference is I was in the 0.001%, had the source code to AutoIt and knew how to hack it up to my needs.
-
Valik got a reaction from Bilgus in _MakeLong, _HiWord, _LoWord
These functions store and retrieve 16 bit values in/from a 32 bit value.
; =================================================================== ; _MakeLong($a, $b) ; ; Concatenates two 16 bit values into one 32 bit value. ; Parameters: ; $l - IN - The low order word (Lowest 16 bits) ; $h - IN - The high order word (Highest 16 bits) ; Returns: ; The two 16 bit values concatenated into a single 32 bit value. ; Notes: ; Retrieve the values with HiWord and LoWord respectively. ; =================================================================== Func _MakeLong($l, $h) Return BitOR(BitAnd($l, 0xFFFF), BitShift(BitAnd($h, 0xFFFF), -16)) EndFunc ; _MakeLong() ; =================================================================== ; _HiWord($x) ; ; Retrieves the high-order word from the 32 bit argument. ; Parameters: ; $x - IN - A 32 bit argument created with _MakeLong() ; Returns: ; The highest 16 bits from the 32 bit integer. ; =================================================================== Func _HiWord(ByRef $x) Return BitShift($x, 16) EndFunc ; _HiWord() ; =================================================================== ; _LoWord($x) ; ; Retrieves the low-oder word from the 32 bit argument ; Parameters: ; $x - IN - A 32 bit argumented created with _MakeLong() ; Returns: ; The lowest 16 bits from the 32 bit integer. ; =================================================================== Func _LoWord(ByRef $x) Return BitAnd($x, 0xFFFF) EndFunc ; _LoWord()
Can be tested with:
Local $a = _MakeLong(100, 200) MsgBox(4096, "High", _HiWord($a)) MsgBox(4096, "Low", _LoWord($a))
Edit: Added ByRef to _HiWord()/_LoWord() to help make sure the correct parameter is passed (Meaning, a literal string can't be passed by somebody incorrectly using those functions).
-
Valik got a reaction from ss26 in dict/hash tables?
No.
No.
You cannot create closures. There are only two visible scopes at any given time, global scope and local (function scope).
Limited recursion is supported.
No.
You can dynamically invoke user-defined functions via Call(). Thus, you don't store a reference to the function itself but rather the name. -
Valik got a reaction from FrancescoDiMuro in Too many code-breaking changes
Goodbye you hypocrite. You are not coming here, insulting us by calling us "script kiddies" and suggesting we are "poor managers" then trying to make moronic comments like "you don't have any right to insult me". As far as I'm concerned you are just trash who doesn't have any right to live. Since I can't (legally) correct that problem I'll do the next best thing: Make you go away for awhile. Maybe spend your time porting your scripts to a deprecated language. 26 day ban for you. Why 26 days? Because this code returned 26:
ConsoleWrite(Random(1, 100, 1) & @CRLF) Have a nice... 26 days.
-
Valik got a reaction from Skysnake in Can a compiled script detect if it was made for CUI or GUI?
You seem to be failing to see the forest for the trees or you have failed to provide a crucial piece of information. Why do you compile the script as CUI? Why not compile it as GUI and write it correctly so that a single flag is checked before any interactive GUI's are shown? Services can be invoked with command line parameters so it is trivial to setup the service invocation with a /service flag which is processed and sets an internal flag which causes all GUI code to be skipped. No reading the PE header. No separate compilation for special circumstances, et cetera. -
Valik got a reaction from Biatu in Easyhook and dll injection
I don't really give a shit whether this post breaks the rules or not. What I do give a shit about is your pathetic attitude. BigDod's opinion on whether or not doesn't matter. Your opinion ESPECIALLY doesn't matter (Do you know how many times people clearly breaking the rules claim they aren't?). The opinion of a moderator matters and this thread required our opinion. BigDod did the exact right thing by reporting it for clarification. You fucked everything up, though, with your shit attitude. If Jos had not beaten me to this thread I would have banned you for a few days for the attitude. Since he beat me here and feels the thread should be locked I'm going to just leave it at that.
So to be clear, this thread isn't locked because it breaks any rules (It might or it might not, I don't care to evaluate that aspect). It's locked because you took a shitty attitude about the whole thing instead of waiting for a moderator to come along and confirm one way or the other. If it weren't for your attitude Jos would have easily deferred to someone with more poker knowledge (Likely me) and I would have bothered to determine if you're breaking the rules or not. As it stands, I don't care. I do, however, strongly discourage you from broaching the subject again on this forum as that is very clearly against the rules.
Next time you claim you have nothing to hide prove it by keeping your word-hole shut until your claims are validated. Trying to vigorously defend yourself with a poor attitude only implies guilt even if there isn't real guilt.
TL;DR version: Use your fucking brain, not your fingers.
-
Valik got a reaction from Earthshine in Software written in AutoIt
The fact that you assume there are limits proves that the limit is you. /endthread
-
Valik got a reaction from mLipok in Software written in AutoIt
The fact that you assume there are limits proves that the limit is you. /endthread
-
Valik got a reaction from mLipok in Global Vars
That's really not an API. An API would be more like this:
#include <GUIConstants.au3> Opt("GUIOnEventMode", 1) Enum $GUI_HWND, $GUI_CLOSEBUTTON, $GUI_MAX Global $g_aGUI[$GUI_MAX] CreateGUI() GUISetState(@SW_SHOW, GUI_GetHWND()) WaitForClose() Func CreateGUI() GUI_SetHWnd(GUICreate("GUI")) GUI_SetCloseButton(GUICtrlCreateButton("Close", 5, 5, 50, 25)) GUICtrlSetOnEvent(GUI_GetCloseButton(), "OnClose") GUISetOnEvent($GUI_EVENT_CLOSE, "OnClose") EndFunc ; CreateGUI() Func WaitForClose() While WinExists(GUI_GetHWND()) Sleep(50) WEnd EndFunc ; WaitForClose() Func OnClose() GUIDelete($g_aGUI[$GUI_HWND]) EndFunc ; OnClose() #Region API Func GUI_SetHWND($hWnd) $g_aGUI[$GUI_HWND] = $hWnd EndFunc ; GUI_SetHWnd() Func GUI_GetHWND() Return $g_aGUI[$GUI_HWND] EndFunc ; GUI_GetHWND() Func GUI_SetCloseButton($id) $g_aGUI[$GUI_CLOSEBUTTON] = $id EndFunc ; GUI_SetCloseButton() Func GUI_GetCloseButton() Return $g_aGUI[$GUI_CLOSEBUTTON] EndFunc ; GUI_GetCloseButton() #EndRegion API The idea is to provide an interface to call into. The interface is all the user should interact with. The fact that the implementation uses a global variable is irrelevant.
Here's a better example of an interface and implementation that are separate that doesn't use global variables:
; =================================================================== ; Project: DocLib Library ; Description: Functions for building the AutoIt documentation. ; Author: Jason Boggs <vampire DOT valik AT gmail DOT com> ; =================================================================== #include-once #Region Members Exported #cs Exported Functions SciTE_Create() - Creates a SciTE object that can be used with SciTE_* functions. The handle returned must be destroyed with SciTE_Destroy(). SciTE_Destroy(ByRef $vHandle) - Destroys a SciTE handle created by SciTE_Create(). SciTE_OpenFile($vHandle, $sFile) - Opens the specified file in the SciTE instance. SciTE_ExportAsHtml($vHandle, $sFile) - Exports the active file to the specified destination. SciTE_CloseFile($vHandle) - Closes the active file. SciTE_SendCommand($vHandle, $sCmd, $hResponse = 0) - Sends the specified command to the SciTE instance. _FileListToArraySorted($sPath, $sFilter = "*", $iFlag = 0) - Returns a file list in a sorted array. #ce Exported Functions #EndRegion Members Exported #Region Includes #include <Array.au3> #include <File.au3> #include <WinAPI.au3> #include <WindowsConstants.au3> #EndRegion Includes #Region Global Variables Global Enum $SCITE_MAINHWND, $SCITE_DIRECTORHWND, $SCITE_MAX #EndRegion Global Variables #Region Library Initialization #EndRegion Library Initialization #Region Public Members #Region SciTE Functions #Region SciTE_Create() ; =================================================================== ; SciTE_Create() ; ; Creates a SciTE object that can be used with SciTE_* functions. The handle returned must ; be destroyed with SciTE_Destroy(). ; Parameters: ; None. ; Returns: ; Success: A handle for use in other SciTE_* functions. ; Failure: 0, sets @error to non-zero as follows: ; 1 - SciTE could not be found. ; 2 - The required properties file could not be found. ; =================================================================== Func SciTE_Create() ; Get the ptah to the required files. Local $sSciTE = __SciTE_FindFile("SciTE.exe") Local $sPropertiesFile = __SciTE_FindFile("au3.keywords.properties") If Not $sSciTE Then Return SetError(1, 0, 0) If Not $sPropertiesFile Then Return SetError(2, 0, 0) ; The -import command requires the .properties extenstion to be stripped. $sPropertiesFile = StringTrimRight($sPropertiesFile, 11) ; Set SciTE_HOME to a directory that doesn't contain global/user properties ; files. This ensures the import statement works correctly. EnvSet("SciTE_HOME", @TempDir) ; Build the full command to start SciTE. $sSciTE = StringFormat('"%s" "-import %s" -check.if.already.open=0', $sSciTE, $sPropertiesFile) ; Run SciTE hidden and store the PID. Local $pid = Run($sSciTE) ; Build the handle to return. Local $vHandle[$SCITE_MAX] $vHandle[$SCITE_MAINHWND] = __SciTE_MainHWNDFromPID($pid) $vHandle[$SCITE_DIRECTORHWND] = __SciTE_DirectorHWNDFromPID($pid) ; Hide the SciTE window because it ignores @SW_HIDE. WinSetState($vHandle[$SCITE_MAINHWND], "", @SW_HIDE) ; Return the handle. Return $vHandle EndFunc ; SciTE_Create() #EndRegion SciTE_Create() #Region SciTE_Destroy() ; =================================================================== ; SciTE_Destroy(ByRef $vHandle) ; ; Destroys a SciTE handle created by SciTE_Create(). ; Parameters: ; $vHandle - IN/OUT - The handle to SciTE. ; Returns: ; Sets @error to non-zero if the handle was invalid. ; =================================================================== Func SciTE_Destroy(ByRef $vHandle) If Not __SciTE_IsValid($vHandle) Then Return SetError(-1, 0, 0) SciTE_SendCommand($vHandle, "quit:") $vHandle = 0 EndFunc ; SciTE_Destroy() #EndRegion SciTE_Destroy() #Region SciTE_OpenFile() ; =================================================================== ; SciTE_OpenFile($vHandle, $sFile) ; ; Opens the specified file in the SciTE instance. ; Parameters: ; $vHandle - IN - The handle to SciTE. ; $sFile - IN - The file to open. ; Returns: ; Sets @error to non-zero if the handle was invalid. ; =================================================================== Func SciTE_OpenFile($vHandle, $sFile) If Not __SciTE_IsValid($vHandle) Then Return SetError(-1, 0, 0) Return SciTE_SendCommand($vHandle, "open:" & StringReplace($sFile, "\", "\\")) EndFunc ; SciTE_OpenFile() #EndRegion SciTE_OpenFile() #Region SciTE_ExportAsHtml() ; =================================================================== ; SciTE_ExportAsHtml($vHandle, $sFile) ; ; Exports the active file to the specified destination. ; Parameters: ; $vHandle - IN - The handle to SciTE. ; $sFile - IN - The destination file to save to. ; Returns: ; Sets @error to non-zero if the handle was invalid. ; =================================================================== Func SciTE_ExportAsHtml($vHandle, $sFile) If Not __SciTE_IsValid($vHandle) Then Return SetError(-1, 0, 0) Return SciTE_SendCommand($vHandle, "exportashtml:" & StringReplace($sFile, "\", "\\")) EndFunc ; SciTE_ExportAsHtml() #EndRegion SciTE_ExportAsHtml() #Region SciTE_CloseFile() ; =================================================================== ; SciTE_CloseFile($vHandle) ; ; Closes the active file. ; Parameters: ; $vHandle - IN - The handle to SciTE. ; Returns: ; Sets @error to non-zero if the handle was invalid. ; =================================================================== Func SciTE_CloseFile($vHandle) If Not __SciTE_IsValid($vHandle) Then Return SetError(-1, 0, 0) Return SciTE_SendCommand($vHandle, "close:") EndFunc ; SciTE_CloseFile() #EndRegion SciTE_CloseFile() #Region SciTE_SendCommand() ; =================================================================== ; SciTE_SendCommand($vHandle, $sCmd, $hResponse = 0) ; ; Sends the specified command to the SciTE instance. ; Parameters: ; $vHandle - IN - The handle to SciTE. ; $sCmd - IN - The command to send. ; $hResponse - IN/OPTIONAL - The optional HWND to a window that will receive a response. ; Returns: ; Sets @error to non-zero if the handle was invalid. ; =================================================================== Func SciTE_SendCommand($vHandle, $sCmd, $hResponse = 0) If Not __SciTE_IsValid($vHandle) Then Return SetError(-1, 0, 0) ; Create a string to hold the command. Local $tCmd = DllStructCreate(StringFormat("char[%d]", StringLen($sCmd) + 1)) DllStructSetData($tCmd, 1, $sCmd) ; Create the COPYDATA structure. Local $tCopyDataStruct = DllStructCreate("ULONG_PTR dwData; DWORD cbData; ptr lpData;") DllStructSetData($tCopyDataStruct, "dwData", 1) DllStructSetData($tCopyDataStruct, "cbData", StringLen($sCmd) + 1) DllStructSetData($tCopyDataStruct, "lpData", DllStructGetPtr($tCmd)) ; Send the command. Return _SendMessageA(__SciTE_GetDirectorHWND($vHandle), $WM_COPYDATA, $hResponse, DllStructGetPtr($tCopyDataStruct), 0, "hwnd", "ptr") EndFunc ; SciTE_SendCommand() #EndRegion SciTE_SendCommand() #EndRegion SciTE Functions #Region _FileListToArraySorted() ; =================================================================== ; _FileListToArraySorted($sPath, $sFilter = "*", $iFlag = 0) ; ; Returns a file list in a sorted array. ; Parameters: ; $sPath - IN - The root path to search. ; $sFilter - IN/OPTIONAL - The file filter to search for. ; $iFlag - IN/OPTIONAL - Specifies whether to return files folders or both: ; 0 - Return both files and folders (Default). ; 1 - Return files only. ; 2 - Return Folders only ; Returns: ; Sucess: A sorted array. ; Failure: 0, sets @error to non-zero. ; =================================================================== Func _FileListToArraySorted($sPath, $sFilter = "*", $iFlag = 0) Local $aFiles = _FileListToArray($sPath, $sFilter, $iFlag) Local Const $nError = @error, $nExtended = @extended _ArraySort($aFiles, 0, 1) Return SetError($nError, $nExtended, $aFiles) EndFunc ; _FileListToArraySorted() #EndRegion _FileListToArraySorted() #EndRegion Public Members #Region Private Members #Region SciTE Private Functions #Region __SciTE_FindFile() ; =================================================================== ; __SciTE_FindFile($sFile) ; ; Searches for the specified file in the standard SciTE locations. ; Parameters: ; $sFile - IN - The filename to search for. ; Returns: ; Success - The path to the specified file. ; Failure - An empty string. ; =================================================================== Func __SciTE_FindFile($sFile) ; Look for the file relative to docs\build. Local $sLocation = "..\..\install\SciTE\" & $sFile If Not FileExists($sLocation) Then ; Look for the file in the AutoIt SciTE directory. $sLocation = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\AutoIt v3\AutoIt", "InstallDir") & "\SciTE\" & $sFile ; Return an empty string if the file was not found. If Not FileExists($sLocation) Then Return "" EndIf ; Return the location if the file was found. Return $sLocation EndFunc ; __SciTE_FindFile() #EndRegion __SciTE_FindFile() #Region __SciTE_GetMainHWND() ; =================================================================== ; __SciTE_GetMainHWND($vHandle) ; ; Retrieves the SciTE window handle. ; Parameters: ; $vHandle - IN - The handle to SciTE. ; Returns: ; Success - The SciTE window handle. ; Failure - 0, sets @error to non-zero. ; =================================================================== Func __SciTE_GetMainHWND($vHandle) If Not __SciTE_IsValid($vHandle) Then Return SetError(-1, 0, 0) Return $vHandle[$SCITE_MAINHWND] EndFunc ; __SciTE_GetMainHWND() #EndRegion __SciTE_GetMainHWND() #Region __SciTE_GetDirectorHWND() ; =================================================================== ; __SciTE_GetDirectorHWND($vHandle) ; ; Retrieves the SciTE Director window handle. ; Parameters: ; $vHandle - IN - The handle to SciTE. ; Returns: ; Success - The SciTE Director window handle. ; Failure - 0, sets @error to non-zero. ; =================================================================== Func __SciTE_GetDirectorHWND($vHandle) If Not __SciTE_IsValid($vHandle) Then Return SetError(-1, 0, 0) Return $vHandle[$SCITE_DIRECTORHWND] EndFunc ; __SciTE_GetDirectorHWND() #EndRegion __SciTE_GetDirectorHWND() #Region __SciTE_MainHWNDFromPID() ; =================================================================== ; __SciTE_MainHWNDFromPID($pid) ; ; Retrieves the SciTE window from the specified PID. ; Parameters: ; $pid - IN - The PID to get the SciTE window from. ; Returns: ; Success - The handle to the SciTE window. ; Failure - 0. ; =================================================================== Func __SciTE_MainHWNDFromPID($pid) Return __SciTE_HWNDFromPID($pid, "[CLASS:SciTEWindow]") EndFunc ; __SciTE_MainHWNDFromPID() #EndRegion __SciTE_MainHWNDFromPID() #Region __SciTE_DirectorHWNDFromPID() ; =================================================================== ; __SciTE_DirectorHWNDFromPID($pid) ; ; Retrieves the SciTE Director window from the specified PID. ; Parameters: ; $pid - IN - The PID to get the SciTE Director window from. ; Returns: ; Success - The handle to the SciTE Director window. ; Failure - 0. ; =================================================================== Func __SciTE_DirectorHWNDFromPID($pid) Return __SciTE_HWNDFromPID($pid, "[CLASS:DirectorExtension]") EndFunc ; __SciTE_DirectorHWNDFromPID() #EndRegion __SciTE_DirectorHWNDFromPID() #Region __SciTE_HWNDFromPID() ; =================================================================== ; __SciTE_HWNDFromPID($pid, $sWindowDescription, $nTimeout = 5000) ; ; Description. ; Parameters: ; $pid - IN - The PID to get the window from. ; $sWindowDescription - IN - An advanced window description of the window. ; $nTimeout - IN/OPTIONAL - How long to wait for the window before giving up. ; Returns: ; Success - The handle to the specified window. ; Failure - 0. ; =================================================================== Func __SciTE_HWNDFromPID($pid, $sWindowDescription, $nTimeout = 5000) Local $nStart = TimerInit() While TimerDiff($nStart) < $nTimeout Local $aList = WinList($sWindowDescription) For $i = 1 To UBound($aList) - 1 If WinGetProcess($aList[$i][1]) = $pid Then Return $aList[$i][1] Next Sleep(250) WEnd Return 0 EndFunc ; __SciTE_HWNDFromPID() #EndRegion __SciTE_HWNDFromPID() #Region __SciTE_IsValid() ; =================================================================== ; __SciTE_IsValid($vHandle) ; ; Tests if the specified handle is valid. ; Parameters: ; $vHandle - IN - The handle to SciTE. ; Returns: ; True - The handle is valid. ; False - The handle is not valid. ; =================================================================== Func __SciTE_IsValid($vHandle) Return UBound($vHandle) = $SCITE_MAX EndFunc ; __SciTE_IsValid() #EndRegion __SciTE_IsValid() #EndRegion SciTE Private Functions #EndRegion Private Members SciTE_Create() returns an opaque handle. The caller doesn't need to worry about what the handle really is, they just pass it to other SciTE_* functions. Even the SciTE_* functions aren't bound to an implementation. If SciTE had a COM interface I could easily change the code to use the COM interface and wouldn't have to touch a single line in any of the SciTE_* functions nor would the caller of the SciTE_* functions need to be changed. Only the __SciTE functions would change because they are the only parts of the code that deal with the implementation.
A design like this is far more flexible and future-proof than a design using global variables. I have pushed all the nasty details far away from where things are used. Things are abstracted away into concepts. The caller only wants to automate SciTE, the caller doesn't care if it uses messages, window automation, a COM interface or command line arguments. The interface doesn't care about those details, either. It only exists to provide an access point between the caller and the raw implementation of the behavior.
-
Valik got a reaction from Alexxander in read command line output
Why use a loop at all?
#include <Constants.au3> Global $DOS, $Message = '' ;; added "= ''" for show only. $DOS = Run(@ComSpec & " /c Ping www.google.com", "", @SW_HIDE, $STDERR_CHILD + $STDOUT_CHILD) ProcessWaitClose($DOS) $Message = StdoutRead($DOS) MsgBox(0, "Stdout Read:", $Message) -
Valik got a reaction from Xandy in GUI/Tray Menu with icons and colors
I was referring to 12 KB of (compiled) C++ code.
Right you are.
What annoyed me most about your idea is it's really coming off as you wanting something for nothing. You really said the wrong things with your narrow focus of only wanting functionality to suit yourself. Most people who want to do something will try to learn to do it.
And it's my personal agenda that AutoIt doesn't require an idiot to use it, either. I constantly harp on the other developer's not to over-simplify things so that advanced functionality can't be achieved. Until Holger's little creation here, I was very hard on JP for over-simplifying the GUI design. Quite literally, I would of rather programmed a GUI in C++ and wrote 200% more code than use AutoIt simply because AutoIt couldn't do the things I wanted. So there is a middle ground that has to be struck in the debate between "simple" and "advanced".
I've never claimed to be the "code defender" or "person-in-charge" nor the "solo spokesperson". It's people like you who go off on insolent rants that give me these titles.
Oh, and by the way. I had a hand in Holger's idea. Holger was stuck and couldn't finish the idea until I came up with a solution and adapted it to suit both Holger and my own needs. So yeah, I kind of did introduce the functionality since the magic that makes it call user functions is my code. I'm not trying to diminish Holger's efforts, most of the code is his and he is the one who put all the work into testing it and documenting it. However, don't assume that because only one developer is listed for a feature that they are the only one who contributed code that makes it work.
Another title which I have not given myself.
Would you like it if I told you to draw me a picture of my house but I limited you to only using circles? Unless I'm a Hobbit or a baby chicken, chances are, you're not going to be able to do what I ask with any semblance of accuracy. Your request follows a similar path of unreasonable and unrealistic thinking. Okay, so pretend we implement all your ideas for how to draw menu's with a very simple API. What if I don't like the way the menu's look when they are drawn this way? Will you consent to having my similar but different API included? What about when the next person comes along, and the person after that, and the person after that? And we're just talking menu's here. There are over a dozen controls in AutoIt and most of them support owner-drawing. Do you see where I'm going with this? Does this make sense to be in the core language?
When you make any feature request, you make it to anybody who has access to the source, especially those of us with updated copies of the source.
Should I be encouraging people to use AutoIt? Shouldn't the strengths of the language be encouragement enough?
Edit: Forgot a paragraph so I added that.
-
Valik got a reaction from pml in Website abuse
Anyone found abusing the website is subject to harsh punishment without warning. A non-exhaustive list of potential abuses include:
Automated forum registration or login. Automated posting or sending messages on the forum. Automated manipulation of polls, user reputation or other forum features. Automated creation or comments on issue tracker tickets. Automated creation or editing of wiki pages. Excessive downloading of pages or files. Excessive frequency when downloading RSS feeds. Other abuses which are either examples of excessive bandwidth usage or automation of the site. Use common sense. If you do not have common sense, don't do anything. Do not automate the forum, wiki or issue tracker in any way at all. Scripts which automatically update AutoIt such as AutoUpdateIt are acceptable as long as they are not abused and do not generate excessive bandwidth usage. -
Valik got a reaction from mLipok in " in a Msg
You seem to have a habit of putting things in the wrong place. I feel sorry for any female you attempt to have sex with. This should be in the v3 Help and Support forum.
-
-
Valik got a reaction from mLipok in Global Vars
Variables should always be declared in the smallest scope possible in any language (for languages that support it). For example, don't front-load your functions with all the variable declarations. Declare variables right before they are used. If a variable doesn't need to exist in global scope then use it in local scope. Prefer function return values and function parameters to pass data around rather than global variables. Keep variables in existence no more than necessary.
-
Valik got a reaction from Synapsee in How to force update of explorer.exe?
Sigh, this is why I don't help you people. I end up having to do all the work myself because you can't manage to solve even the most simple of problems. First, Obviously different versions of Windows are using a different class. CabinetWClass is pre-Vista and the other is post-Vista. Or something like that, I don't feel like booting Vista to verify. Second, who gives a fuck, really? Get the right handle to start with and cut out 60% of the code in the process.
Func _Update_Explorer() Local $bOld = Opt("WinSearchChildren", True) Local $a = WinList("[CLASS:SHELLDLL_DefView]") For $i = 0 To UBound($a) - 1 DllCall("user32.dll", "long", "SendMessage", "hwnd", $a[$i][1], "int", 0x111, "int", 28931, "int", 0) Next Opt("WinSearchChildren", $bOld) EndFunc;==>_Update_Explorer -
Valik got a reaction from rcmaehl in Latest Beta
What the hell is all this non-sense about?
ConsoleWrite("AutoIt version: " & @AutoItVersion & @CRLF) Local Writer = ConsoleWrite Writer("What the hell, this works?" & @CRLF) Writer = MyConsoleWrite Writer("This works, too!?" & @CRLF) Func MyConsoleWrite(sText) ConsoleWrite("MyConsoleWrite(): " & sText) EndFunc
Output:
AutoIt version: 3.3.9.5 What the hell, this works? MyConsoleWrite(): This works, too!?
Tomorrow... maybe...
-
Valik got a reaction from Biatu in How to force update of explorer.exe?
Sigh, this is why I don't help you people. I end up having to do all the work myself because you can't manage to solve even the most simple of problems. First, Obviously different versions of Windows are using a different class. CabinetWClass is pre-Vista and the other is post-Vista. Or something like that, I don't feel like booting Vista to verify. Second, who gives a fuck, really? Get the right handle to start with and cut out 60% of the code in the process.
Func _Update_Explorer() Local $bOld = Opt("WinSearchChildren", True) Local $a = WinList("[CLASS:SHELLDLL_DefView]") For $i = 0 To UBound($a) - 1 DllCall("user32.dll", "long", "SendMessage", "hwnd", $a[$i][1], "int", 0x111, "int", 28931, "int", 0) Next Opt("WinSearchChildren", $bOld) EndFunc;==>_Update_Explorer -
Valik got a reaction from mLipok in The devs of autoit...
I find a lot of your recent posts ridiculous too. Should I moderate you just because you've been incredibly stupid and annoying lately? What about all the other stupid annoying bullshit that comes up everyday? Do we moderate all that, too?
-
Valik got a reaction from UrgessyTrek in Forum rules updated
I updated the Forum Rules today to clarify expected behavior when reporting spammers. The additional text is included below. If you have not read the forum rules I strongly suggest you take this opportunity to do so.
Reporting Spammers
There are a couple special notes regarding spammers:
Report the spam post but do not acknowledge it in any way. Do not quote it, post something "witty" about it or post "reported". The latter is a particularly bad habit some people have. This creates extra work for the moderators and serves no purpose. Not only do the moderators have to delete the spam post but they must also delete your post. Even if a particular post is reported multiple times it only creates one report on the back-end with all the report comments so there is really no reason to announce you have reported a spammer. If a user makes multiple spam posts it is only necessary to report one post. In your report comment mention that the user has other spam posts so we know to look at their content to find the others. In all likelihood each post will end up getting reported by other people anyway. One report and a note to check the other posts is sufficient, however.