All Activity

This stream auto-updates   

  1. Past hour
  2. is possible to make something like in attached file ? simply borderless GUI with a centered read only label text [maybe auto sized GUI] c message.bmp
  3. _IECreate returns an object, however WinExists requires a handle. As to your second problem, it seems that calling WinExists with an empty string (or an unassigned variable in your case) for the Window Name always returns True. If you set it to 0 it won't say that the window exists. #include <MsgBoxConstants.au3> #include <IE.au3> Global $oIE2 = 0, $oIE3 = 0 Example() Func Example() $oIE3 = _IECreate("www.google.com") $hWnd = _IEPropertyGet($oIE3, "hwnd") ; Wait 10 seconds for the Notepad window to appear. Sleep(10000) ; Test if the window exists and display the results. If WinExists($hWnd) Then MsgBox($MB_SYSTEMMODAL, "1", "Window exists") Else MsgBox($MB_SYSTEMMODAL, "1", "Window does not exist") EndIf If WinExists($oIE2) Then MsgBox($MB_SYSTEMMODAL, "2", "Window exists") Else MsgBox($MB_SYSTEMMODAL, "2", "Window does not exist") EndIf EndFunc ;==>Example
  4. @Melba23 I am sorry but I could not get, which post is amended.
  5. Eg for Client to Client ? Client group ?
  6. Unfortunately that's exactly what you do right now It seems you missed to read the forum rules on your way in. Please do so now. Game automation of any kind is not allowed here. Hope to see you with a legitimate question quite soon
  7. Today
  8. thanks for your reply, water. It's a game honestly. when you open it, it just starts at window mode. The winactivate functions well because it puts it at front or into active. I hope I'm not breaking any rules here. I just wanted to do coding and gaming at the same time since those two are my favorite hobbies.
  9. thanks for your reply, water. It's a game honestly. when you open it, it just starts at window mode. The winactivate functions well because it puts it at front or into active. I hope I'm not breaking any rules here. I just wanted to do coding and gaming at the same time since those two are my favorite hobbies.
  10. @Melba23, there are few applications which are not for fun or public purpose. They might be for internal or corporate applications which is why not everyone would like to disclose each and every aspect of the application. I think I had mentioned many times what am I expecting from the sample GUI. Clicking Lables will bring in more lables and Buttons and hide the previous ones. Next, new buttons will do the required actions they are meant for, Button 2 will get the Default view back in place and Button 3 will do whatever further actions. That's the only thing I needed, which I have but getting into some issues. No issues, I understand from your point of view too for staying long enough with this thread and thank you for the inputs and suggestions you have given. I think spending sometime myself will let me know what needs to be done. Just to let you know, within your GUIExtender, there is one of the example I liked and was something in my mind to get something similar. And I think I can use that in future stage on my other applications. Have a good day.
  11. Hi guys I found this topic Delphi Wrapper but can't use on Delphi the commands: - AU3_WinGetHandle - AU3_WinGetTitle I don't have any idea how to use it... I got the error: Exception EAccessViolation in module AutoItX3.dll at 00033473... Would you please be so kind to share the correct way to use? Thanks a lot in advance.
  12. Yes, The Kandie Man is correct do it with TCP triggers.
  13. Thanks a lot for all your explanations RTFC I understand mutexes, etc. On my case, it´s more something like you told, creating a joint workspace where multiple processes can act simultanuously. That´s the reason I suggested the "AT". Au3, as any other language, has to allocate space for it´s variables, no mater if they are dynamic typing like AU3. Anyway, when you declare a variable, area must be allocated to it (or when you assign a value to it). So, if we could tell AU3 "use the area starting at this point" for the variables created at this Global or Local declaration line, that would make much more simple and so fast as plain variables to share data betwen processes. While we do not have "AT", seemos to me the best thing for me is to give a deeper look at your E4A to see how you handle this common workspace, and use dllCreate, .... Later I will worry about mutexes. Use of mutexes depends largely on how you code and how specific or generic is your code. For example, windows has a bunch of them with names and forms like fork trees, queues, etc., etc. I believe that AU3 manages just one "memory allocation area" for it´s dynamic variables creation. To implement "AT", it shoud manage distinct "memory allocation areas". While this seems not so complicated, it is deep change and probably would not justify the effort versus the number of people interested on that. But, on ohter hand, parallel computing with so many processors avaiable at any PC, that could be an improvement.
  14. Searched a little more and found the thread below. Will give Kurt's solution a try and go from there.
  15. Yesterday
  16. I'm attempting to capture the output from the command line tool PSEXEC. I'm using AutoIT to run an instance of PSEXEC against a remote PC to audit Local Admins in my environment using net.exe (C:\Windows\System32> net localgroup administrators). However the usual trick I use to capture command line output does not appear to work well with PSEXEC, as the bottom portion of the output is missing from the return. Any ideas or recommendations are greatly appreciated. Here is what I'm working with: ;This script will read from a list of hosts and report who has local admin privileges on the machine #RequireAdmin Global $fileName = @ScriptDir & '\test.txt' ;hostlist, one host per line readHostList() ;Read list of hosts Func readHostList() Local $file = FileOpen($fileName, 0) While 1 $line = FileReadLine($file) If @error = -1 Then ExitLoop ConsoleWrite($line & @CRLF) ;MsgBox(0,0,$line) getLocalAdmins($line) WEnd FileClose($file) EndFunc ;run PSEXEC to list local admins Func getLocalAdmins($remotePC) Local $testFile = @ScriptDir &'\test234.txt' FileOpen($testFile, 1) Local $psexec = 'psexec \\' & $remotePC & ' net localgroup administrators' FileWriteLine($testFile, _RunCmd($psexec) ) FileClose($testFile) EndFunc ;Used to return CLI output Func _RunCmd($sCommand) Local $nPid = Run(@Comspec & " /c" & $sCommand, @SystemDir, @SW_Hide, 8), $sRet = "" If @Error then Return "ERROR:" & @ERROR ProcessWait($nPid) While 1 $sRet &= StdoutRead($nPID) If @error Or (Not ProcessExists ($nPid)) Then ExitLoop WEnd Return $sRet EndFunc ## If i manually run the command on the remote PC via PSEXEC I will get the following output: PsExec v2.11 - Execute processes remotely Copyright (C) 2001-2014 Mark Russinovich Sysinternals - www.sysinternals.com Starting net on PCNAME... on PCNAME... net exited on PCNAME with error code 0. ------------------------------------------------------------------------------- admin Administrator Alias name administrators Domain\Domain Admins Comment Administrators have complete and unrestricted access to the computer/domain Members The command completed successfully. ## The returned output from running the above script is as follows: PsExec v2.11 - Execute processes remotely Copyright (C) 2001-2014 Mark Russinovich Sysinternals - www.sysinternals.com Alias name administrators Connecting to PCNAME... Starting PSEXESVC service on PCNAME... Connecting with PsExec service on PCName... Starting net on PCNAME.. net exited on PCNAME with error code 0. **Note to test this script PSEXEC must be in the system dir or the path in the script changed PSEXEC tool: https://docs.microsoft.com/en-us/sysinternals/downloads/psexec
  17. I think it was the following, but I need to doublecheck later on my tablet, BC
  18. What was the code you used that worked? i mean in the normal windows.
  19. I give the user an option to start 5 different web pages through a GUI. Then I want to manipulate the pages they have chosen to open. First, I need to see which pages they have chosen to open. I suppose I could just create a Boolean solution; when they choose a page set it to True, but isn't there a way to check if a page exists? I copied the code below right from the WinExists help file, added IE to it, and it appears to do the opposite! If the page is open the message says "Window does not exist" and for the check that does not exist I get "Window exists"! What is the best way to see if the user has activated $oIE1, $oIE2, $oIE3, etc.? #include <MsgBoxConstants.au3> #include <IE.au3> Global $oIE2, $oIE3 Example() Func Example() $oIE3 = _IECreate("www.google.com") ; Wait 10 seconds for the Notepad window to appear. Sleep(10000) ; Test if the window exists and display the results. If WinExists($oIE3) Then MsgBox($MB_SYSTEMMODAL, "1", "Window exists") Else MsgBox($MB_SYSTEMMODAL, "1", "Window does not exist") EndIf If WinExists($oIE2) Then MsgBox($MB_SYSTEMMODAL, "2", "Window exists") Else MsgBox($MB_SYSTEMMODAL, "2", "Window does not exist") EndIf EndFunc ;==>Example
  20. youtuber, Do not be so impatient - some of us have more important things to do. This works for me: #include <GUIConstantsEx.au3> $Form1 = GUICreate("Unescape Decoder and Encoder", 876, 422, 192, 124) $Edit1 = GUICtrlCreateEdit("AutoitTest", 48, 48, 337, 305) $Edit2 = GUICtrlCreateEdit("", 412, 49, 425, 305) $Label1 = GUICtrlCreateLabel("String", 56, 24, 50, 17) $Label2 = GUICtrlCreateLabel("Unescape", 416, 24, 50, 17) $ButtonEncoder = GUICtrlCreateButton("Encoder", 150, 376, 147, 25) $ButtonDecoder = GUICtrlCreateButton("Decoder", 550, 376, 147, 25) GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $ButtonEncoder $sBinary = StringTrimLeft(StringToBinary(GUICtrlRead($Edit1)), 2) $sEscaped = StringRegExpReplace($sBinary, "(.{2})", "%$1") GUICtrlSetData($Edit2, $sEscaped) GUICtrlSetData($Edit1, "") Case $ButtonDecoder $sEncoded = GUICtrlRead($Edit2) $sStripped = StringReplace($sEncoded, "%", "") ConsoleWrite($sStripped & @CRLF) $sDecoded = BinaryToString("0x" & $sStripped) ConsoleWrite($sDecoded & @CRLF) GUICtrlSetData($Edit1, $sDecoded) EndSwitch WEnd M23
  21. Can you help me please #include <Array.au3> #include <ButtonConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <StaticConstants.au3> #include <WindowsConstants.au3> $Form1_1 = GUICreate("Unescape Decoder and Encoder", 877, 669) $Edit1 = GUICtrlCreateEdit("", 48, 48, 337, 249) GUICtrlSetData(-1, "AutoitTest") $Edit2 = GUICtrlCreateEdit("", 412, 49, 425, 249) $Label1 = GUICtrlCreateLabel("String", 56, 24, 50, 17) $Label2 = GUICtrlCreateLabel("Unescape", 416, 24, 50, 17) $ButtonEncoder = GUICtrlCreateButton("Encoder", 150, 312, 147, 25) $ButtonDecoder = GUICtrlCreateButton("Decoder", 550, 312, 147, 25) $Edit3 = GUICtrlCreateEdit("", 40, 408, 801, 233) $Label3 = GUICtrlCreateLabel("Decode", 40, 384, 122, 17) GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $ButtonEncoder $aData = StringTrimLeft(StringToBinary(GUICtrlRead($Edit1)), 2) $aArray = _StringEqualSplit($aData, 2) GUICtrlSetData($Edit2, "%" & _ArrayToString($aArray, "%")) Case $ButtonDecoder GUICtrlSetData($Edit3,GUICtrlRead($Edit2) EndSwitch WEnd Func _StringEqualSplit($sString, $iNumChars) If (Not IsString($sString)) Or $sString = "" Then Return SetError(1, 0, 0) If (Not IsInt($iNumChars)) Or $iNumChars < 1 Then Return SetError(2, 0, 0) Return StringRegExp($sString, "(?s).{1," & $iNumChars & "}", 3) EndFunc
  22. XinYoung, You just need to create child GUIs on each of the tabs and hide/show them as you change the tab selection. The Tabs tutorial in the Wiki shows how you can do this. M23
  23. DigDeep, Not the slightest explanation at all of what exactly is going on, so as I said earlier I am out of this thread - bye. M23
  24. I seem to have started to guess what the problem is! I checked the download of sites via IE! And it turned out that he just does not load them at all. And then I remembered that I once found information that the old version of IE (8) does not support the protocol Let's Encrypt - Free SSL / TLS Certificates(and these sites are just using it)! And it's like the truth! And maybe just unfortunately the function _INetGetSource (like the others like it) works through IE and its settings. That's why this function does not work for me. It looks like the truth? But a slightly newer version of IE, I can not put it because I have to use more WinXP. And completely disconnect the security check in IE does not want to of course.
  25. Moved to the appropriate forum, as the Technical Discussion forum clearly states:
  26. I am trying to set the date in a date picker field not created by autoit (shown in the attached images). I did not create this field. It already exists in the window. I used the following code: ; enter from date $sFromDate = "09/01/2017" ControlFocus($hWnd, "", "WindowsForms10.SysDateTimePick32.app.01") ControlSetText($hWnd, "", "WindowsForms10.SysDateTimePick32.app.01", $sFromDate ) As the AutoIt Window Info gave me info about the control but not the specific items ( month/day/year) inside the control. How to set the date? Thanks.
  27. Yes, of course - this is not excluded. But of course I did it first.
  1. Load more activity