All Activity

This stream auto-updates   

  1. Past hour
  2. The application I am looking at is part of a commercial software suite to manage desktops (Novell Zenworks) and is not downloadable as such. I can send you the agent install exe, but it is around 500 MB. I have not tried the winmove yet, as the disabling of the buttons is a prerequisite: if that does not work, the maximizing is not needed anymore. Cheers, BC
  3. If you point me to a application i can download and test it would help. What was the result on the winmove?
  4. DigDeep, You said earlier that you will have 30+ such "applications" - will each and every one of them have a similar set of buttons? If so, I foresee huge problems in keeping them in order and preventing total confusion. Might I suggest using my GUIExtender UDF? You can then have everything in a single GUI with a section for each "application" and just display the section required. This will allow you to create all the required controls at the beginning of the script (or at least those that need auctioning) which will greatly simplify the whole process. Take a look at the UDF (the link is in my sig) and I will try and write a short example which I hope will demonstrate how I think It might help you. M23
  5. No, you delete it in your original code. With the changes I made it closes. Try this updated version, should work better. #include <ButtonConstants.au3> #include <ComboConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <StaticConstants.au3> #include <WindowsConstants.au3> #include <FileConstants.au3> #include <File.au3> #include <GUIListBox.au3> Main_Form() Func Main_Form() #Region ### START Koda GUI section ### Form=c:\users\elahr.vitacost\documents\autoit scripts\form1.kxf $Form1 = GUICreate("", 798, 401, 177, 114) $Label1 = GUICtrlCreateLabel("Display Request Form", 0, 8, 715, 41, $SS_CENTER) GUICtrlSetFont(-1, 24, 800, 0, "MS Sans Serif") $Input1 = GUICtrlCreateInput("0", 416, 120, 81, 21, BitOR($GUI_SS_DEFAULT_INPUT, $ES_CENTER)) $Combo1 = GUICtrlCreateCombo("", 16, 120, 385, 25, BitOR($CBS_DROPDOWN, $CBS_AUTOHSCROLL)) $Combo2 = GUICtrlCreateCombo("", 16, 152, 385, 25, BitOR($CBS_DROPDOWN, $CBS_AUTOHSCROLL)) $Combo3 = GUICtrlCreateCombo("", 16, 184, 385, 25, BitOR($CBS_DROPDOWN, $CBS_AUTOHSCROLL)) $Combo4 = GUICtrlCreateCombo("", 16, 216, 385, 25, BitOR($CBS_DROPDOWN, $CBS_AUTOHSCROLL)) $Combo5 = GUICtrlCreateCombo("", 16, 248, 385, 25, BitOR($CBS_DROPDOWN, $CBS_AUTOHSCROLL)) $Input2 = GUICtrlCreateInput("0", 416, 152, 81, 21, BitOR($GUI_SS_DEFAULT_INPUT, $ES_CENTER)) $Label2 = GUICtrlCreateLabel("URL to Display", 120, 80, 139, 28, $SS_CENTER) GUICtrlSetFont(-1, 14, 800, 0, "MS Sans Serif") $Label3 = GUICtrlCreateLabel("Minutes", 417, 82, 77, 28, $SS_CENTER) GUICtrlSetFont(-1, 14, 800, 0, "MS Sans Serif") $Input3 = GUICtrlCreateInput("0", 416, 184, 81, 21, BitOR($GUI_SS_DEFAULT_INPUT, $ES_CENTER)) $Input4 = GUICtrlCreateInput("0", 416, 216, 81, 21, BitOR($GUI_SS_DEFAULT_INPUT, $ES_CENTER)) $Input5 = GUICtrlCreateInput("0", 416, 248, 81, 21, BitOR($GUI_SS_DEFAULT_INPUT, $ES_CENTER)) $Button1 = GUICtrlCreateButton("Open Page and Configure", 645, 120, 139, 17) $Button2 = GUICtrlCreateButton("Begin Display", 168, 293, 355, 33) GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif") $Button3 = GUICtrlCreateButton("Add or Remove URL", 205, 347, 291, 33) GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif") $Button4 = GUICtrlCreateButton("Open Page and Configure", 645, 153, 139, 17) $Button5 = GUICtrlCreateButton("Open Page and Configure", 645, 187, 139, 17) $Button6 = GUICtrlCreateButton("Open Page and Configure", 645, 217, 139, 17) $Button7 = GUICtrlCreateButton("Open Page and Configure", 645, 251, 139, 17) $Label4 = GUICtrlCreateLabel("Refresh", 536, 80, 76, 28) GUICtrlSetFont(-1, 14, 800, 0, "MS Sans Serif") $Radio1 = GUICtrlCreateRadio("", 566, 120, 17, 17) $Radio2 = GUICtrlCreateRadio("", 566, 152, 17, 17) $Radio3 = GUICtrlCreateRadio("", 566, 184, 17, 17) $Radio4 = GUICtrlCreateRadio("", 566, 217, 17, 17) $Radio5 = GUICtrlCreateRadio("", 566, 250, 17, 17) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### Local $oFile = @ScriptDir & "\URL_List.txt" $file = FileOpen($oFile, 0) ; Check if file opened for reading OK If $oFile = -1 Then MsgBox(0, "Error", "Unable to open file.") Exit EndIf While 1 $line = FileReadLine($file) If @error = -1 Then ExitLoop GUICtrlSetData($Combo1, $line) GUICtrlSetData($Combo2, $line) GUICtrlSetData($Combo3, $line) GUICtrlSetData($Combo4, $line) GUICtrlSetData($Combo5, $line) WEnd FileClose($oFile) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Button3 ;~ GUIDelete($Form1) <<<<<<<<<<<<<< Not needed, unless you want to have to readd everything all of the time ;~ You can hide it if you need to make it not visible while using Form2 GUISetState(@SW_HIDE, $Form1) URL_Config() $file = FileOpen($oFile, 0) ; Read in lines of text until the EOF is reached While 1 $line = FileReadLine($file) If @error = -1 Then ExitLoop GUICtrlSetData($Combo1, $line) GUICtrlSetData($Combo2, $line) GUICtrlSetData($Combo3, $line) GUICtrlSetData($Combo4, $line) GUICtrlSetData($Combo5, $line) WEnd FileClose($oFile) GUISetState(@SW_SHOW, $Form1) EndSwitch WEnd EndFunc ;==>Main_Form Func URL_Config() Local $oFile = @ScriptDir & "\URL_List.txt" FileOpen($oFile, 0) ; Check if file opened for reading OK If $oFile = -1 Then MsgBox(0, "Error", "Unable to open file.") Exit EndIf #Region ### START Koda GUI section ### Form=C:\Users\elahr.VITACOST\Documents\AutoIT Scripts\Form2.kxf $Form2 = GUICreate("Add or Remove URL", 543, 671, 250, 14) $List1 = GUICtrlCreateList("", 24, 40, 497, 344) $Label1 = GUICtrlCreateLabel("Select URL to Remove", 0, 8, 539, 32, $SS_CENTER) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") $Button1 = GUICtrlCreateButton("Remove", 40, 392, 465, 33) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") $Input1 = GUICtrlCreateInput("", 24, 504, 497, 21) $Label2 = GUICtrlCreateLabel("Enter URL to Add", 0, 472, 539, 32, $SS_CENTER) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") $Button2 = GUICtrlCreateButton("Add", 43, 532, 465, 33) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") $Button3 = GUICtrlCreateButton("Return to Display Setup", 39, 610, 465, 33) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### For $i = 1 To _FileCountLines($oFile) $line = FileReadLine($oFile, $i) GUICtrlSetData($List1, $line) Next While 1 $nMsg = GUIGetMsg() Switch $nMsg ;~ Case $GUI_EVENT_CLOSE ;~ Exit Case $Button1 $select = GUICtrlRead($List1) For $i = 1 To _FileCountLines($oFile) $line = FileReadLine($oFile, $i) If $line = $select Then _FileWriteToLine($oFile, $i, "", True) _GUICtrlListBox_ResetContent($List1) For $z = 1 To _FileCountLines($oFile) $oLine = FileReadLine($oFile, $z) GUICtrlSetData($List1, $oLine) Next ExitLoop EndIf Next Case $Button2 $new = GUICtrlRead($Input1) GUICtrlSetData($Input1, "") ;MsgBox(0, "", "Input: " & $new) If $new <> "" Then FileWriteLine($oFile, $new) _GUICtrlListBox_ResetContent($List1) For $z = 1 To _FileCountLines($oFile) $oLine = FileReadLine($oFile, $z) GUICtrlSetData($List1, $oLine) Next If $new = "" Then MsgBox(0, "Error", "There is nothing to add.") ;~ URL_Config() <<<<<<<<<<<<<<<<<<< Recursing the function Case $Button3, $GUI_EVENT_CLOSE GUIDelete($Form2) ;~ Main_Form() <<<<<<<<<<<<<<<<< Recursing the first function Return EndSwitch WEnd EndFunc ;==>URL_Config
  6. Hi, I could send you one, but I am not sure it will work if I just send the executable. BC
  7. That example should work on files other than .mui files, its not possible to edit .mui files with updateresource
  8. My application will be holding multiple Lables and Buttons which will Enable / Disable, Hide / Show at certain times. Button 2 is something to be used as Go Back option to the Default view when the application launches. Button 3 is something that will be used as to do some further activities. To explain better, GUI launches > APP2 2 clicked will launch Button 2 and Button 3 > If button 2 is pressed it will Hide everything Inside APP2() > If Button 3 is pressed, I will decide further what actions to take so only Button 2 will Hide.
  9. How so? It appears to decode your string just fine. Perhaps you should provide a more details response indicating what you are trying to accomplish and how this UDF doesn't meet your needs.
  10. youtuber, It is a simple ASCII conversion: #include <MsgBoxConstants.au3> $sString = "AutoIt" $sCoded = StringTrimLeft(StringToBinary($sString), 2) MsgBox($MB_SYSTEMMODAL, "Encoded", $sCoded) $sDecoded = BinaryToString("0x" & $sCoded) MsgBox($MB_SYSTEMMODAL, "Decoded", $sDecoded) M23
  11. I've tried many things, can't seem to read the correct array. #RequireAdmin #include <File.au3> #include <Array.au3> #include <FileConstants.au3> Find() Func Find() #include <File.au3> #include <Array.au3> #include <FileConstants.au3> Local $aFinal[1][2] $aFinal[0][0] = "File" $aFinal[0][1] = "Time" $aFileList = _FileListToArrayRec(@ScriptDir, "*", $FLTAR_FILES, $FLTAR_RECUR, $FLTAR_SORT, $FLTAR_RELPATH) For $a = 1 To $aFileList[0] _ArrayAdd($aFinal, $aFileList[$a] & "|" & FileGetTime(@ScriptDir & "\" & $aFileList[$a], $FT_CREATED, $FT_STRING)) Next For $i = 0 To UBound($aFinal[2]) - 1 If $i > "20170924999999" Then MsgBox(0, "", $aFinal[0][$a]) EndIf Next _ArrayDisplay($aFinal) EndFunc ;==>Find
  12. DigDeep, Now you have al the code in one place I can see the problem - you are continually recreating controls in APP2 which, of course, overlap and hence do not fire when actioned. What exactly is the difference between $Button2 and $Button3? Why is $Button3 supposed to stay there when pressed - recreating that control each time in your major problem. Perhaps if you were to explain in a bit more detail exactly what is supposed to happen within your script I could suggest a script architecture which would simplify your task. M23
  13. What I'm talking about is different from your thread http://www.tareeinternet.com/scripts/unescape.html
  14. Today
  15. That would be because you are reading from the wrong array.
  16. #RequireAdmin #include <File.au3> #include <Array.au3> #include <FileConstants.au3> Find() Func Find() #include <File.au3> #include <Array.au3> #include <FileConstants.au3> Local $aFinal[1][2] $aFinal[0][0] = "File" $aFinal[0][1] = "Time" $aFileList = _FileListToArrayRec(@ScriptDir, "*", $FLTAR_FILES, $FLTAR_RECUR, $FLTAR_SORT, $FLTAR_RELPATH) For $a = 1 To $aFileList[0] _ArrayAdd($aFinal, $aFileList[$a] & "|" & FileGetTime(@ScriptDir & "\" & $aFileList[$a], $FT_CREATED, $FT_STRING)) If $aFileList[1] > "20170922999999" Then MsgBox(0, "", $aFileList[$a]) EndIf Next _ArrayDisplay($aFinal) EndFunc ;==>Find
  17. Hopefully, I do not offend anyone by saying that the code in CLR.au3 is a bit messy. DotNet.au3 is primarily a rewrite of CLR.au3 so the code appears a bit nicer. And at the same time it's a complete translation of CLR.ahk. DotNet.au3 (and CLR.ahk) can also be used on Windows XP. I'm not very excited about the .NET Framework or .NET code, so don't expect a lot of code from me. There are a few topics that I find interesting, which I also find interesting from an AutoIt point of view. One of these topics is the ability to execute compiled code in particular in relation to array manipulations. This is illustrated in the example with prime numbers. So this is the kind of examples with just a few code lines I have in mind. And for such small pieces of code, I don't think I need anything more advanced than this. All examples I've tested works fine. There are a few other topics I find interesting. Maybe I'll make a couple of examples for these topics. The section in first post about .NET concepts is just a simple overview. It certainly is not the full picture of anything. And I don't think you need the full picture to use the UDF or to add compiled C# or VB code to your AutoIt scripts.
  18. I'm having trouble reading the Time column in the array: #RequireAdmin #include <File.au3> #include <Array.au3> #include <FileConstants.au3> Find() Func Find() #include <File.au3> #include <Array.au3> #include <FileConstants.au3> Local $aFinal[1][2] $aFinal[0][0] = "File" $aFinal[0][1] = "Time" $aFileList = _FileListToArrayRec(@ScriptDir, "*", $FLTAR_FILES, $FLTAR_RECUR, $FLTAR_SORT, $FLTAR_RELPATH) For $a = 1 To $aFileList[0] _ArrayAdd($aFinal, $aFileList[$a] & "|" & FileGetTime(@ScriptDir & "\" & $aFileList[$a], $FT_CREATED, $FT_STRING)) Next If $aFileList[$a][1] > "20150101" Then MsgBox(0, "", $aFileList[$a]) EndIf _ArrayDisplay($aFinal) EndFunc ;==>Find
  19. Thanks for the help. BrewManNH, I added $GUI_EVENT_CLOSE to my $Button3 code on $Form2 as you suggested. It made no change for me. I posted because I thought this would be a known bug. I figured this had to have come up before or I am doing something very wrong. I can easily toggle between both forms: start program, click $Button3 on $Form1, it disappears and $Form2 is presented, click $Button3 on $Form2, it disappears and $Form1 is presented all as expected. However, if I type anything into $Input1 on $Form2 and use the 'Add' button ($Button2) to add the typed text to the listbox, when I use $Button3 on $Form2 to toggle back to $Form1, $Form1 appears as before with focus but $Form2 remains and does not disappear until I close the whole program. Small thing but it would be much cleaner if it worked. Very strange. Thanks again for your valuable input!
  20. @Melba23 Here is the updated single AU3 file clubbed in... Could you please help. Parent Application.au3
  21. Use the AddPicture method to add the picture. Set LinkToFile to msoTrue and SaveWithDocument to msoFalse. Replace the file with the new picture (the name needs to remain unchanged) and you are set.
  22. Thanks alot @kylomas first example helped me.
  23. Oh i forgot i changed my mp3 files with wma files :D.Thank you very much :).
  24. Unfortunately I have never used the Firefox UDF so I can't help you with this problem. Hopefully some experienced Firefox coder chimes in
  25. Personal preference, but I would get it into your array first (usually easier to manipulate) and then add the array to your csv. Something like this: #include <File.au3> #include <Array.au3> #include <FileConstants.au3> Local $aFinal[1][2] $aFinal[0][0] = "File" $aFinal[0][1] = "Time" $aFileList = _FileListToArrayRec(@ScriptDir, "*", $FLTAR_FILES, $FLTAR_RECUR, $FLTAR_SORT, $FLTAR_RELPATH) For $a = 1 To $aFileList[0] _ArrayAdd($aFinal, $aFileList[$a] & "|" & FileGetTime(@ScriptDir & "\" & $aFileList[$a], $FT_CREATED, $FT_STRING)) Next _ArrayDisplay($aFinal)
  26. Couple of things: You aren't showing the whole script as you have a call to a FUNC that isn't shown: Call ("Ajde") Don't use Call() but simply do : VelikiOdmor() You aren't testing for the success of the _FileListToArrayRec() and assume there is an Array with at least 2 places. Check for the @Error & [0] to know the number of files returned. There are a couple of other warnings when ran through au3check. Jos
  27. @JLogan3o13 Yes, thanks for the heads up. I'm still unable to get the "Created" time. How can I write both the file name with path and the modified time to the same csv file so I can then check which file was created after January 1 2014? Thanks again for your help. I'm still chipping away at this.
  1. Load more activity