Leaderboard
Popular Content
Showing content with the highest reputation on 12/11/2024 in all areas
-
Input box with up\down control but using hex as the input
pixelsearch and 2 others reacted to ioa747 for a topic
Was the dot in GUICtrlCreateUpdown #include <GUIConstantsEx.au3> #include <EditConstants.au3> Local $sMyHex = "FFFFFF" $hGUI = GUICreate("Test", 500, 500) $cInput = GUICtrlCreateInput($sMyHex, 10, 100, 100, 20, $ES_CENTER) $cDummyInput = GUICtrlCreateInput(Int("0x" & $sMyHex), 110, 100, 100, 20) $cUpDown = GUICtrlCreateUpdown($cDummyInput) GUICtrlSetLimit($cUpDown, 16777215, 0) ; Set range for valid 6-digit hex values (0 to FFFFFF) GUICtrlSetState($cDummyInput, $GUI_FOCUS) GUISetState() While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE Exit Case $cDummyInput ; Remove the dot Local $intValue = Int(StringReplace(GUICtrlRead($cDummyInput), ".", "")) Local $sHexValue = Hex($intValue, 6) ; Convert to 6-digit hex GUICtrlSetData($cInput, $sHexValue) EndSwitch WEnd3 points -
Input box with up\down control but using hex as the input
pixelsearch and one other reacted to Melba23 for a topic
TwoCanoe, For simplicity, I would use a dummy input like this: #include <GUIConstantsEx.au3> #include <EditConstants.au3> Local $sMyHex = "0000FF" $hGUI = GUICreate("Test", 500, 500) $cInput = GUICtrlCreateInput(String($sMyHex), 10, 100, 100, 20, $ES_CENTER) $cDummyInput = GUICtrlCreateInput(Dec($sMyHex), 110, 100, 20, 20) $cUpDown = GUICtrlCreateUpdown($cDummyInput) GUICtrlSetState($cDummyInput, $GUI_FOCUS) GUISetState() While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE Exit Case $cDummyInput GUICtrlSetData($cInput, Hex(Number(GUICtrlRead($cDummyInput)), 6)) EndSwitch WEnd Increase the width of the dummy input to see what is going on. M232 points -
[New VERSION] - 11 Dec 24 Added: New function _GUIListViewEx_EditProcessActive which returns the handle of the ListView concerned if an element is being edited. Usage scenario: prevent HotKeys from working when editing is underway. Fixed: A couple of bugs with columns: added columns were automatically sortable; dragging columns meant editing pop-up could appear in wrong place. Thanks to ValentinM for the reports. New UDF in the first post. M232 points
-
Input control with label and rounded corners
argumentum and one other reacted to ioa747 for a topic
Input control for the GUI with label and rounded corners It all started in this post I tried to make a rectangle with rounded corners, using $GUI_GR_BEZIER. I managed to do it but the result did not satisfy me because $GUI_GR_BEZIER produced (is producing) a rough result. A flickering, which I could not overcome. So I changed the approach with two rectangles and a circle for each corner The script demonstrates the use of functions to create input fields with and without labels, and rounded corners, where the font size changes dynamically depending on the height of Input control. Valid value for Corner [0=Rectangle] to [($Height/2)=Round], Default=($Height/4) Example1: _CreateInputWL() #include <GUIConstants.au3> _Example() ;---------------------------------------------------------------------------------------- Func _Example() Local $hGUI = GUICreate("Shipping Details", 390, 320) GUISetStyle(-1, $WS_EX_COMPOSITED) GUISetBkColor(0x0D1117) Local $ShippingDetails = GUICtrlCreateLabel("Shipping Address", 10, 5, 380, 30) GUICtrlSetFont(-1, 18, 800, 0, "MS Sans Serif") GUICtrlSetColor(-1, 0xFFD800) Local $Exit = GUICtrlCreateButton("EXIT", 20, 270, 95, 40) GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif") GUICtrlSetColor(-1, 0x0D1117) GUICtrlSetBkColor(-1, 0xFFD800) Local $Corner = -1 ; *** <- Valid value from [0=Rectangle] to [($Height/2)=Round], Default=($Height/4) *** <- Local $FirstName = _CreateInputWL("First Name:", "John", 10, 50, 180, 40, 0x00FFFF, $Corner) Local $LastName = _CreateInputWL("Last Name:", "Doe", 200, 50, 180, 40, 0x00FFFF, $Corner) Local $Address = _CreateInputWL("Address:", "123 Main St", 10, 100, 230, 40, 0x00FFFF, $Corner) Local $Apt = _CreateInputWL("Apt:", "4B", 250, 100, 130, 40, 0x00FFFF, $Corner) Local $City = _CreateInputWL("City:", "Springfield", 10, 150, 140, 40, 0x00FFFF, $Corner) Local $State = _CreateInputWL("State:", "IL", 160, 150, 80, 40, 0x00FFFF, $Corner) Local $ZipCode = _CreateInputWL("Zip Code:", "627 01", 250, 150, 130, 40, 0x00FFFF, $Corner) Local $Email = _CreateInputWL("Email:", "jdoe627@gmail.com", 10, 200, 230, 40, 0x00FFFF, $Corner) Local $Phone = _CreateInputWL("Phone:", "0123456789", 250, 200, 130, 40, 0x00FFFF, $Corner) GUISetState(@SW_SHOW) Sleep(4000) GUICtrlSetData($Email[0], "Johndoe@gmail.com") GUICtrlSetData($Phone[1], "Mobile:") GUICtrlSetData($Phone[0], "654210789") ;********************************** While True Switch GUIGetMsg() Case $GUI_EVENT_CLOSE, $Exit ExitLoop EndSwitch WEnd ;********************************** EndFunc ;==>_Example ;---------------------------------------------------------------------------------------- Func _CreateInputWL($Label, $Text, $Left, $Top, $Width, $Height, $Color, $Corner = -1) ; $Corner Valid value [0=Rectangle] to [($Height/2)=Round], Default=($Height/4) ; Validate parameters If $Corner < 0 Or $Corner = Default Then $Corner = $Height / 4 If $Corner > $Height / 2 Then $Corner = $Height / 2 If $Width <= 0 Or $Height <= 0 Then Return SetError(1, 0, 0) EndIf ; graphic GUICtrlCreateGraphic($Left, $Top, $Width, $Height) GUICtrlSetGraphic(-1, $GUI_GR_COLOR, $Color, $Color) ; body GUICtrlSetGraphic(-1, $GUI_GR_RECT, $Corner, 0, $Width - ($Corner * 2), $Height) ; outer part GUICtrlSetGraphic(-1, $GUI_GR_RECT, 0, $Corner, $Width, $Height - ($Corner * 2)) ; inner part ; corners GUICtrlSetGraphic(-1, $GUI_GR_ELLIPSE, 0, 0, $Corner * 2, $Corner * 2) ; Top-left GUICtrlSetGraphic(-1, $GUI_GR_ELLIPSE, $Width - $Corner * 2, 0, $Corner * 2, $Corner * 2) ; Top-right GUICtrlSetGraphic(-1, $GUI_GR_ELLIPSE, 0, $Height - $Corner * 2, $Corner * 2, $Corner * 2) ; Bottom-left GUICtrlSetGraphic(-1, $GUI_GR_ELLIPSE, $Width - $Corner * 2, $Height - $Corner * 2, $Corner * 2, $Corner * 2) ; Bottom-right GUICtrlSetState(-1, $GUI_DISABLE) Local $idLabel = GUICtrlCreateLabel($Label, $Left + $Corner, $Top, $Width - ($Corner * 2), $Height * 0.4) GUICtrlSetBkColor($idLabel, $Color) GUICtrlSetFont($idLabel, $Height * 0.25) Local $idInput1 = GUICtrlCreateInput($Text, $Left + $Corner, $Top + ($Height * 0.35), $Width - ($Corner * 2), $Height * 0.60, -1 ,$WS_EX_COMPOSITED) GUICtrlSetFont($idInput1, $Height * 0.35) GUICtrlSetBkColor($idInput1, $Color) Local $aRet[] = [$idInput1, $idLabel] Return $aRet ; Return both ID EndFunc ;==>_CreateInputWL ;---------------------------------------------------------------------------------------- Example2: _CreateInputWL(), _CreateInput() #include <GUIConstants.au3> Global $hGUI = GUICreate("GUI") GUISetStyle ( -1, $WS_EX_COMPOSITED ) GUISetBkColor(0x0D1117) Global $id_1 = _CreateInput("INPUT1", 20, 20, 150, 30, "0xFFD800", 15) Global $id_2 = _CreateInput("INPUT2", 20, 60, 150, 30, "0xB6FF00") Global $id_3 = _CreateInput("INPUT3", 20, 100, 150, 35, "0x00FFFF", 10) Global $id_4 = _CreateInput("INPUT4", 20, 145, 150, 35, "0x0094FF") Global $id_5 = _CreateInput("INPUT5", 20, 190, 150, 40, "0xFF0000", 10) Global $id_6 = _CreateInput("INPUT6", 20, 240, 150, 40, "0xFF80EE") Global $id_7 = _CreateInputWL("Label:", "INPUT7", 220, 20, 150, 30, "0xFFD800", 10) Global $id_8 = _CreateInputWL("Label:", "INPUT8", 220, 60, 150, 30, "0xB6FF00") Global $id_9 = _CreateInputWL("Label:", "INPUT9", 220, 100, 150, 35, "0x00FFFF", 10) Global $id_10 = _CreateInputWL("Label:", "INPUT10", 220, 145, 150, 35, "0x0094FF") Global $id_11 = _CreateInputWL("Label:", "INPUT11", 220, 190, 150, 40, "0xFF0000", 10) Global $id_12 = _CreateInputWL("Label:", "INPUT12", 220, 240, 150, 40, "0xFF80EE") Global $id_13 = _CreateInputWL("LabelXXL:", "INPUTXXL", 20, 300, 350, 60, "0xB6B6B6", 30) GUISetState() While True Switch GUIGetMsg() Case $GUI_EVENT_CLOSE ExitLoop EndSwitch WEnd ;---------------------------------------------------------------------------------------- Func _CreateInput($Text, $Left, $Top, $Width, $Height, $Color, $Corner = 10) ; $Corner Valid value [0=Rectangle] to [($Height/2)=Round], Default=($Height/4) ; Validate parameters If $Corner < 0 Or $Corner = Default Then $Corner = $Height / 4 If $Corner > $Height / 2 Then $Corner = $Height / 2 If $Width <= 0 Or $Height <= 0 Then Return SetError(1, 0, 0) EndIf ; graphic GUICtrlCreateGraphic($Left, $Top, $Width, $Height) GUICtrlSetGraphic(-1, $GUI_GR_COLOR, $Color, $Color) ; body GUICtrlSetGraphic(-1, $GUI_GR_RECT, $Corner, 0, $Width - ($Corner * 2), $Height) ; outer part GUICtrlSetGraphic(-1, $GUI_GR_RECT, 0, $Corner, $Width, $Height - ($Corner * 2)) ; inner part ; corners GUICtrlSetGraphic(-1, $GUI_GR_ELLIPSE, 0, 0, $Corner * 2, $Corner * 2) ; Top-left GUICtrlSetGraphic(-1, $GUI_GR_ELLIPSE, $Width - $Corner * 2, 0, $Corner * 2, $Corner * 2) ; Top-right GUICtrlSetGraphic(-1, $GUI_GR_ELLIPSE, 0, $Height - $Corner * 2, $Corner * 2, $Corner * 2) ; Bottom-left GUICtrlSetGraphic(-1, $GUI_GR_ELLIPSE, $Width - $Corner * 2, $Height - $Corner * 2, $Corner * 2, $Corner * 2) ; Bottom-right GUICtrlSetState(-1, $GUI_DISABLE) $idInput1 = GUICtrlCreateInput($Text, $Left + $Corner, $Top + ($Height * 0.2), $Width - ($Corner * 2), $Height * 0.6, -1, $WS_EX_COMPOSITED) GUICtrlSetFont($idInput1, $Height * 0.4, 400) GUICtrlSetBkColor($idInput1, $Color) Return $idInput1 EndFunc ;==>_CreateInput ;---------------------------------------------------------------------------------------- Func _CreateInputWL($Label, $Text, $Left, $Top, $Width, $Height, $Color, $Corner = -1) ; $Corner Valid value [0=Rectangle] to [($Height/2)=Round], Default=($Height/4) ; Validate parameters If $Corner < 0 Or $Corner = Default Then $Corner = $Height / 4 If $Corner > $Height / 2 Then $Corner = $Height / 2 If $Width <= 0 Or $Height <= 0 Then Return SetError(1, 0, 0) EndIf ; graphic GUICtrlCreateGraphic($Left, $Top, $Width, $Height) GUICtrlSetGraphic(-1, $GUI_GR_COLOR, $Color, $Color) ; body GUICtrlSetGraphic(-1, $GUI_GR_RECT, $Corner, 0, $Width - ($Corner * 2), $Height) ; outer partt GUICtrlSetGraphic(-1, $GUI_GR_RECT, 0, $Corner, $Width, $Height - ($Corner * 2)) ; inner part ; corners GUICtrlSetGraphic(-1, $GUI_GR_ELLIPSE, 0, 0, $Corner * 2, $Corner * 2) ; Top-left GUICtrlSetGraphic(-1, $GUI_GR_ELLIPSE, $Width - $Corner * 2, 0, $Corner * 2, $Corner * 2) ; Top-right GUICtrlSetGraphic(-1, $GUI_GR_ELLIPSE, 0, $Height - $Corner * 2, $Corner * 2, $Corner * 2) ; Bottom-left GUICtrlSetGraphic(-1, $GUI_GR_ELLIPSE, $Width - $Corner * 2, $Height - $Corner * 2, $Corner * 2, $Corner * 2) ; Bottom-right GUICtrlSetState(-1, $GUI_DISABLE) Local $idLabel = GUICtrlCreateLabel($Label, $Left + $Corner, $Top, $Width - ($Corner * 2), $Height * 0.4) GUICtrlSetBkColor($idLabel, $Color) GUICtrlSetFont($idLabel, $Height * 0.25) Local $idInput1 = GUICtrlCreateInput($Text, $Left + $Corner, $Top + ($Height * 0.35), $Width - ($Corner * 2), $Height * 0.60, -1, $WS_EX_COMPOSITED) GUICtrlSetFont($idInput1, $Height * 0.35) GUICtrlSetBkColor($idInput1, $Color) Local $aRet[]=[$idInput1, $idLabel] Return $aRet ; Return both ID EndFunc ;==>_CreateInputWL ;---------------------------------------------------------------------------------------- Please, every comment is appreciated! leave your comments and experiences here! Thank you very much2 points -
[New VERSION] - 11 Dec 24 Added: New function _GUIListViewEx_EditProcessActive which returns the handle of the ListView concerned if an element is being edited. Usage scenario: prevent HotKeys from working when editing is underway. Fixed: A couple of bugs with columns: added columns were automatically sortable; dragging columns meant editing pop-up could appear in wrong place. Thanks to ValentinM for the reports. New UDF in the zip below. -------------------------------------------------------------------------------------- Note: This is a new recoded and expanded version of my earlier UDF of the same name. If you move to this new version there might well be several script-breaking changes, particularly when setting which columns are to be editable. Please read the "Beginner's Guide" and look at the included example scripts to see where things have changed. -------------------------------------------------------------------------------------- This UDF allows you to do much more with ListView controls (either native or UDF created): Edit the content with plain text, combos or date-time pickers - and edit the headers too Move rows within the ListView Drag rows both within the ListView and to other ListViews in the same GUI (or not as required) Insert and delete columns and rows Sort columns by simply clicking the header Colour individual ListView items and headers Only select a single cell rather then the entire row Save and load entire ListViews For the advanced user: If you use certain Windows message handlers (In particular WM_NOTIFY) in your script, please read the function headers for the equivalent handlers within the UDF. Here is the UDF, with 6 examples and the guide, in zip format: GUIListViewEx.zip Credit to: martin (basic drag code), Array.au3 authors (array functions), KaFu and ProgAndy (font function), LarsJ (colouring code) Happy to take compliments or criticism - preferably the former! M231 point
-
Input box with up\down control but using hex as the input
ioa747 reacted to pixelsearch for a topic
Hi everybody I have 2 remarks concerning this thread : 1) The dot / comma issue described in the preceding posts would not happen if the UpDown control was created like this : ; $cUpDown = GUICtrlCreateUpdown($cDummyInput) $cUpDown = GUICtrlCreateUpdown($cDummyInput, BitOR($GUI_SS_DEFAULT_UPDOWN, $UDS_NOTHOUSANDS)) Because as seen in the preceding posts, as soon as you reach 1000 (decimal, e.g. 0x3E8 hex) then an issue occurs due to the thousand separator found in the hidden Input control. 2) On my computer it's not a dot, it's not a comma... but it's a space that I use as thousand separator in my windows regional settings. So maybe it could be useful, when necessary, to avoid the hard-coded syntax... ; Remove the dot (or the comma or the space etc...) ; Local $intValue = Int(StringReplace(GUICtrlRead($cDummyInput), ".", "")) ; Local $intValue = Int(StringReplace(GUICtrlRead($cDummyInput), ",", "")) ; Local $intValue = Int(StringReplace(GUICtrlRead($cDummyInput), " ", "")) ...then we could check instead what are the user locale settings, for example in this case, the $sThousandSymbol should do it in all cases : #include <APILocaleConstants.au3> #include <WinAPILocale.au3> Local $iLCID = _WinAPI_GetUserDefaultLCID() Local $sThousandSymbol = _WinAPI_GetLocaleInfo($iLCID, $LOCALE_STHOUSAND) ConsoleWrite('Thousand symbol >>>' & $sThousandSymbol & "<<<" & @crlf) ; usually . or , or space ConsoleWrite('Decimal symbol >>>' & _WinAPI_GetLocaleInfo($iLCID, $LOCALE_SDECIMAL) & "<<<" & @crlf) ; usually . or , Let's hope my different approach, using 2 UpDown control messages ($UDM_SETBASE and $UDM_SETRANGE32), solves OP's question in any case, though I'm not satisfied for now with the 2 parameters (-1 and 0) associated to $UDM_SETRANGE32 . I'll try to dig a bit.1 point -
ListUserSessions
maniootek reacted to argumentum for a topic
..is a mess of code. Didn't code thinking of sharing it, given that the script is an app and the code is all over the forum. Not all things work as expected. The idle time of the other sessions may not work.** What the app does is to shadow a session. Instead of using the command line, I made this to "click click" into a session. Thought that others may have use for it and shared it. The ones that do admin know how to set the PC up for it's use, others, I will not enlighten as it could be misused. ** If needed in an "unattended fashion", a script with _WinAPI_GetIdleTime() could provide the admin that info, with an API that loads on every user on login ( we all here can put something like that together in a thousand different ways ) . But my aim was to give live support to a user and the user would be on the phone, knowing that am shadowing the session to click-click on their behalf as if magic, because some users are really clueless. This solves the problem without a teamviewer/rustDest or what not, that could expose the workstation to unauthorized entry ( due to zero-day, etc. )1 point -
Input box with up\down control but using hex as the input
ioa747 reacted to pixelsearch for a topic
Another approach, based on UpDown control messages : #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <SendMessage.au3> #include <WindowsConstants.au3> Opt("MustDeclareVars", 1) ;0=no, 1=require pre-declaration MyGUI() Func MyGUI() Local $Gui, $Input, $h_Updown, $MyHex = "0x88AAFF" $Gui = GUICreate("My GUI", 200, 200, 300, 150) $Input = GUICtrlCreateInput("", 50, 50, 100, 30, $ES_CENTER) $h_Updown = GUICtrlGetHandle(GUICtrlCreateUpDown(-1)) Local $UDM_SETBASE = $WM_USER + 109 ; in CommCtrl.h _SendMessage($h_Updown, $UDM_SETBASE, 16, 0) ; base 16 in this script Local $UDM_SETRANGE32 = $WM_USER + 111 ; _SendMessage($h_Updown, $UDM_SETRANGE32, -1, 0) ; experimented... but changing these values seems to create issues. _SendMessage($h_Updown, $UDM_SETRANGE32, 0, 0xFFFFFFFF) ; equivalent to 0, -1 GUICtrlSetData($Input, $MyHex) GUISetState(@SW_SHOW) While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd EndFunc1 point -
ioa747, Solved! This sampling has literally saved me a ton of work!! Therefore... "Muchas gracias! Merci mille fois! Grazie mille! Danke sehr! Dankjewel! Çok tesekkürler! Stokrotne dziek! Asante San! Dakujem! Tusen takk!" ...and finally, "Thanks a million!"1 point
-
recommend ; ----------------------------------------------- #include <File.au3> #include <GUIConstantsEx.au3> #include <MsgBoxConstants.au3> #include <WindowsConstants.au3> ; ----------------------------------------------- Opt("MustDeclareVars", 1) ; ----------------------------------------------- _Gui1() ; ----------------------------------------------- Func _Gui1() ;$h_Gui1 = GUICreate("GUI 1", 145, 135, 125, 100) ;~ Local $h_Gui1 = GUICreate("GUI 1", 145, 135, -1, -1, -1, $WS_EX_TOOLWINDOW) Local $h_Gui1 = GUICreate("GUI 1", 145, 135) GUISetFont(14, 800, 0, "Calibri") ; ----------------------------------------------- Local $idButton1a = GUICtrlCreateButton("Launch SAW", 10, 10, 125, 25) ;Local $idButton1c = GUICtrlCreateButton("Add SoundFile", 10, 40, 125, 25) Local $idButton1c = GUICtrlCreateButton("Enable Button", 10, 40, 125, 25) Local $idButton1b = GUICtrlCreateButton("Exit SAW", 10, 70, 125, 25) Local $idButton1d = GUICtrlCreateButton("Exit", 10, 100, 125, 25) GUISetState(@SW_SHOW, $h_Gui1) GUICtrlSetTip($idButton1c, "add SoundFile HotKey is now disabled!") Local $idMsg ; ----------------------------------------------- While 1 $idMsg = GUIGetMsg() Switch $idMsg Case $GUI_EVENT_CLOSE ExitLoop Case $idButton1a _LaunchSAWWMM() Case $idButton1b _ExitSAW() Case $idButton1d _ExitMe() Case $idButton1c _EnableHotKey($idButton1c) EndSwitch WEnd ; ----------------------------------------------- GUIDelete($h_Gui1) EndFunc ;==>_Gui1 ; ----------------------------------------------- Func _LaunchSAWWMM() Local $_sSrcPath = "C:\RML\SAW\SAWStudio64.exe" ; ------------------------------------------------ Run($_sSrcPath) MouseMove(340, 195, 0) Sleep(2000) EndFunc ;==>_LaunchSAWWMM ; ----------------------------------------------- Func _ExitSAW() Local $_sSrcPath1a = "C:\RML\SAW\SAWStudio64.exe" Local $_sSrcPath1b = "SAWStudio64.exe" Local $PID = 0 ; ----------------------------------------------- ProcessClose($_sSrcPath1a) $PID = ProcessExists($_sSrcPath1b) If $PID Then ProcessClose($PID) EndFunc ;==>_ExitSAW ; ----------------------------------------------- Func _EnableHotKey($idButton) Local Static $hbHotKeyEnabled = True ;ConsoleWrite("$hbHotKeyEnabled=" & $hbHotKeyEnabled & @CRLF) If $hbHotKeyEnabled = True Then ; To enable hotkeys HotKeySet("{APPSKEY}", "_AccessMenuOption") GUICtrlSetData($idButton, "Disable HotKey") GUICtrlSetTip($idButton, "add SoundFile HotKey is now enabled!") $hbHotKeyEnabled = False ToolTip("Select [APPSKEY] to add SoundFile!", 84, 17, "HotKey Enabled", 1, $TIP_BALLOON) Else ; To disable hotkeys HotKeySet("{APPSKEY}") GUICtrlSetData($idButton, "Enable HotKey") GUICtrlSetTip($idButton, "add SoundFile HotKey is now disabled!") $hbHotKeyEnabled = True ToolTip("Select [Enable HotKey] to enable.", 84, 17, "HotKey Disabled", 1, $TIP_BALLOON) EndIf ; Provide time to dispay ToolTip Sleep(2000) ToolTip("") EndFunc ;==>_EnableHotKey ; ----------------------------------------------- Func _AccessMenuOption() ConsoleWrite("Add SoundFile - ok" & @CRLF) Return ; <- *** just for testing <- ; ----------------- WinActivate("[CLASS:SAWSTUDIO_MAIN]", "") WinMenuSelectItem("[CLASS:SAWSTUDIO_MAIN]", "", "&File", "Add SoundFile To MT") EndFunc ;==>_AccessMenuOption ; ----------------------------------------------- Func _ExitMe() Exit EndFunc ;==>_ExitMe ; -----------------------------------------------1 point
-
Add (On_close_Secondary()) to the On_Button2a() function, something like this: Func On_Button2a() ;at the end of the hotkey code add this: On_Close_Secondary() EndFunc ;==>On_Button2a It will close the secondary gui after the hotkey is set.1 point
-
That fixed it so far. I'll keep testing to see if there are any anomalies otherwise. Thanks Jos.1 point
-
[solved] How using $GUI_GR_BEZIER ?
argumentum reacted to ioa747 for a topic
Here I changed the approach with two rectangles and a circle for each corner 212533-input-control-with-label-and-rounded-corners/1 point -
Code Fixed: Mode 1: #include <File.au3> $file = "c:\yourfile.txt" FileOpen($file, 0) For $i = 1 to _FileCountLines($file) $line = FileReadLine($file, $i) msgbox(0,'','the line ' & $i & ' is ' & $line) Next FileClose($file) Mode 2: #include <file.au3> $file = FileOpen("yourfile.txt", 0) While 1 $line = FileReadLine($file) If @error = -1 Then ExitLoop MsgBox(0,'',$line) WEnd FileClose($file) Mode 3: #include <Array.au3> #include <File.au3> Local $aInput $file = "yourfile.txt" _FileReadToArray($file, $aInput) For $i = 1 to UBound($aInput) -1 MsgBox (0,'',$aInput[$i]) Next all tested!1 point