All Activity

This stream auto-updates   

  1. Past hour
  2. #includes hierarchy does not converge What does it mean?
  3. Today
  4. I'm new to AutoIt and programming/scripting in general and have been having some trouble getting scripts I create on my personal machine to run the same on my work computer. I'm running windows 10 enterprise on both machines and Functions like _IENavigate and _IETagNameGetCollection don't seem to read the DOM when executed on my work computer, unless I run it with Administrative permissions I haven't been able to get around this. I've been unsuccessful searching the forum and google for this particular issue. Any Suggestions? #include <IE.au3> #include <Array.au3> #include <String.au3> $asset = InputBox("PC Search", "Search by AM", "", "", 100, 120) If @error = 0 Then $oIE = _IECreate("" & $asset & "?Min=2&", 0, 0) $h4 = _IETagNameGetCollection($oIE, "h4") For $title In $h4 If IsObj($title) Then Local $arr = StringSplit($title.innerhtml, "", 2) $string = _ArrayToString($arr, "", 11, 24, "", 11, 24) InputBox("Search Results", "Found String", $string, "", 100, 120) EndIf Next Else EndIf
  5. Never mind, Finally just figured it out ; Write the REG_SZ value of "WK.exe". RegWrite("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\DirectDraw\Compatibility\WK.1.exe", "Name", "REG_SZ", "WK.exe") ; Write the REG_BINARY value of flags and ID $BinFlag = '0x00800000' $BinID = '0xec33743b' RegWrite("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\DirectDraw\Compatibility\WK.1.exe", "Flags", "REG_BINARY", binary($BinFlag)) RegWrite("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\DirectDraw\Compatibility\WK.1.exe", "ID", "REG_BINARY", binary ($BinID))
  6. Hello, I need help inserting these keys and values to registry [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\DirectDraw\Compatibility\WK.1.exe] "Flags"=hex:00,08,00,00 "ID"=hex:ec,33,74,3b Still can't figure out how...
  7. Yes. You could do it with a combination of _IsPressed to capture the right mouse being pressed and released and MouseWheel to do your scrolling up and down. Look at the examples in the help file for details. Not sure why you want to trigger it on the right mouse button since it triggers a context menu in most applications. Here's a very simple example: #include <Misc.au3> example() Func example() Local $hDll = DllOpen("user32.dll") While True Sleep(10) ;If right mouse button pressed If _IsPressed("02", $hDll) Then ;Wait until no longer pressed While _IsPressed("02", $hDll) Sleep(10) WEnd ;Do your action MsgBox(0, "Example", "Right mouse button released") ExitLoop EndIf WEnd DllClose($hDll) EndFunc
  8. IE <> Edge, so the IE.au3 UDF is not going to be of much use to you.
  9. Hi, Is there a way to have the edge browser embedded in autoit using the IE.au3 UDF or another way? I'd like to use the script to display html pages as well as pdfs for notifications? Thanks
  10. Is this what you want? GUICreate("RTL GUI", 170, 100, -1, -1, -1) ;, $WS_EX_LAYOUTRTL) $LV = GUICtrlCreateListView('Items', 10, 10, 150, 80) GUICtrlCreateListViewItem('C (50 of 200)', $LV) GUICtrlCreateListViewItem('14-DA-E9-0F-82-8B', $LV) _GUICtrlListView_JustifyColumn($LV, 0, 0) _GUICtrlListView_SetColumnWidth($LV, 0, 140) GUISetState() While GUIGetMsg() <> $GUI_EVENT_CLOSE WEnd Note that both RTL and LTR text display correctly when no layout direction is specified: GUICreate("RTL GUI", 470, 400, -1, -1, -1) ;, $WS_EX_LAYOUTRTL) $LV = GUICtrlCreateListView('Items', 10, 10, 350, 380) GUICtrlCreateListViewItem('French: voici mon texte', $LV) GUICtrlCreateListViewItem('Hebrew: הנה הטקסט שלי', $LV) GUICtrlCreateListViewItem('Arabic: هنا هو نصي', $LV) GUICtrlCreateListViewItem('Chinese: 这是我的文字', $LV) GUICtrlCreateListViewItem('Urdu: یہاں میرا متن ہے', $LV) _GUICtrlListView_JustifyColumn($LV, 0, 1) _GUICtrlListView_SetColumnWidth($LV, 0, 240) GUISetState() While GUIGetMsg() <> $GUI_EVENT_CLOSE WEnd
  11. Yesterday
  12. Why not just use AutoIt to create the folders, you can then utilize the variables in the remainder of your script: Global $sTaskBarInfo = EnvGet("SystemDrive") & "\Apps\Taskbar Info" Global $sComputer = $sTaskBarInfo & "\ComputerName\" & @ComputerName Global $sUserName = $sTaskBarInfo & "\UserName\" & @UserName & "@" & @LogonDomain DirCreate($sComputer) DirCreate($sUserName)
  13. Hello my friends, I'm a big noob. I want to make a script which scrolls up the mouse wheel one time and then scrolls down one time AFTER I released (not pressed) the right mouse button. Is this possible with AutoIt? Thanks in advance
  14. Hello, this udf + dll is the maximum for printing without using other applications (word - excel - pdf - etc.) The only lack is the impossibility of being able to set the size of the sheet! I have to print a report on an A2 sheet how do I do it? Thank you
  15. Fantastic! (And what a relief!) I never noticed this one small statement amidst all the talk about bitmaps: Thanks very much!
  16. down to 5 lines and the feeling at least 1 more should be possible with the ? operator on the GUIGetMsg(1) Local $j=0, $2=0, $amsg[]=[0,0,0,0,0], $BA[] = ["7", "8", "9", "+", "C", "4", "5", "6", "-", "SqRt", "1", "2", "3", "*", ".", "0", "(", ")", "/", "="], $hGui = GUICreate("Calc", 360, 330, 229, 118), $D = GUICtrlCreateInput("", 8, 8, 344, 31, BitOR(0x00000080, 2)), $1 = GUISetState(@SW_SHOW),$2 = GUICtrlCreateButton($BA[0],7,50,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"), $2 = GUICtrlCreateButton($BA[1],77,50,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[2],147,50,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[3],217,50,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[4],287,50,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[5],7,120,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[6],77,120,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[7],147,120,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[8],217,120,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[9],287,120,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[10],7,190,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[11],77,190,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[12],147,190,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[13],217,190,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[14],287,190,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[15],7,260,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[16],77,260,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[17],147,260,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[18],217,260,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif"),$2 = GUICtrlCreateButton($BA[19],287,260,65, 63) + GUICtrlSetFont(-1, 18, 400, 0, "MS Sans Serif") Do $aMsg = GUIGetMsg(1) ;Get as array ; Should be possible with a ? somewhere if ($aMsg[2]=0 ? $2=0 : (GUICtrlRead($aMsg[0]) = "C" ? GUICtrlSetData($D, "") : GUICtrlRead($aMsg[0]) = "SqRt" ? GUICtrlSetData($D, Sqrt(Execute(GUICtrlRead($D)))) : GUICtrlRead($aMsg[0]) = "=" ? GUICtrlSetData($D, Execute(GUICtrlRead($D))) : GUICtrlSetData($D, GUICtrlRead($D) & GUICtrlRead($aMsg[0]))) and ($aMsg[0]=-3)) Then exit Until $aMsg[0] = -3 ; $GUI_EVENT_CLOSE
  17. That seems to work. thanks.
  18. OS: Windows 10 Professional I need to be able to display the computer name and domain\username of a user on their desktop taskbar (not system tray, and not wallpaper) in a large-scale environment. I'd like to script this and deploy via GPO. I'm using the "New Toolbar" option when right-clicking on the taskbar and selecting "Toolbars" and selectin "New toolbar...", and then selecting a folder. The folder's title will become the toolbar itself. However, the folder and its title is generated via the script I wrote which titles out the computer name, domain used, and username logged in upon running the script. So half the work is done. I am trying to use AutoIt to simply open the "New Toolbar - Choose a folder" browse box and selecting the folder to display as a toolbar... but the AutoIt v3 Windows tool cannot ascertain the Title of this browse box or the UI for the taskbar in order to select the folders generated so they may be applied as it should look in the attachment to this post. Here's my script so far, a batch file for generating the folders and their titles correctly: (this will title out the created folder based upon the PC Name, User logged, and Domain used, for every time the script is ran) ======================taskbarinfo=========================== rmdir C:\Apps\"Taskbar Info" /s /q md C:\Apps\"Taskbar Info" md C:\Apps\"Taskbar Info"\ComputerName md C:\Apps\"Taskbar Info"\UserName\ md C:\Apps\"Taskbar Info"\ComputerName\%ComputerName% md C:\Apps\"Taskbar Info"\UserName\%UserName%@%UserDomain% =========================================================== Could someone point out to me the Title of this box so I can use it in the SciTE Script Editor? Once I have the Title, I can run this box and then do the rest of selections easily. Here's what the finished product should look like: Side note: I'm already using BgInfo for wallpaper IT info for each workstation, but I need Computer Name, Domain, and User Name shown where it is always visible; taskbar. If you know of a 3rd party program (and I tried looking for hours) than can simply do this job WITHOUT clicking any buttons, just displaying these 3 details 24/7/365, then I'll happily take up the suggestion. Thank you.
  19. Yep, that looks familiar all right. #RequireAdmin RunWait (@ComSpec & " /c " & 'cscript.exe offscrub07.vbs ALL /Q /NoCancel') Run (@ComSpec & " /c " & "shutdown /r /t 30 /d P:4:1") But for some reason, the first step of the VBS fails with a perms error regarding the registry when called from AutoIt. Still digging into what might be causing that. So the VBS fails, the sandbox system reboots, and I'm back to the drawing board. I'll dig into this more tomorrow for sure.
  20. WinGetHandle("Purchase order") If WinExists('Purchase failed') Or WinExists('Qnt not permitted') Then     WinClose('Purchase failed')     WinClose('Purchase order')     WinClose('Qnt not permitted') Else     MsgBox(0, 'Text', 'Purchase completed') EndIf
  21. Certainly looks like the tech. Thank you very kindly, Danp2.
  22. Here's a very simple example using notepad windows. #include <Array.au3> ;Launch 4 notepad windows Run("notepad.exe") Run("notepad.exe") Run("notepad.exe") Run("notepad.exe") ;Wait a couple of seconds for the windows to load Sleep(2000) ;Get a list of the window handles Local $aWinList = WinList("Untitled - Notepad") _ArrayDisplay($aWinList) ;Resize and move windows WinMove($aWinList[1][1], "", 0, 0, 200, 200) WinMove($aWinList[2][1], "", 200, 0, 200, 200) WinMove($aWinList[3][1], "", 0, 200, 200, 200) WinMove($aWinList[4][1], "", 200, 200, 200, 200) Since I'm not sure how new to AutoIt you are, when you see the display of the array, close it, and the script will continue.
  23. Maybe this is what you are looking for? Custom URI
  24. What is the tech called that enables a link click to be detected in any browser? For example when I click a magnet metalink or bitorrent link in a browser, my torrent client opens it, even if the client is not running. Need it for a torrent client project. No idea what to search for after "detect link click" etc.. just turns up hundreds of pages of webbrowser controls references.
  25. Great. With this hint just edited AutoIt3Wrapper.au3.
  26. Not sure if this would help, but here is what I used when upgrading our Office 2003/2007 clients to Office 2013 #RequireAdmin Opt("ExpandVarStrings", 1) ;~ Uninstall Office 2003 If RegRead('HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{90110409-6000-11D3-8CFE-0150048383C9}', 'DisplayName') Then RunWait('@ComSpec@ /c cscript "@ScriptDir@\OffScrub03.vbs" PIA,PROPLUS /S /OSE /BYPASS 1 /NOCANCEL /Quiet', '', @SW_HIDE) EndIf ;~ Uninstall Office 2007 If RegRead('HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{90120000-0011-0000-0000-0000000FF1CE}', 'DisplayName') Then RunWait('@ComSpec@ /c cscript "@ScriptDir@\OffScrub07.vbs" EXPDFXPS,PIA,PROPLUS /S /OSE /BYPASS 1 /NOCANCEL /Quiet', '', @SW_HIDE) EndIf
  27. I have a window where I need to insert some data to make a purchase order. I can get 2 errors if the order is not filled in correctly (Purchased failed & Qnt not permitted). What I want to do is to check if an error window is generated and if it is (Purchased failed or Qnt not permitted), to close the error window and the Purchase Order window. I am using the below code: WinGetHandle("Purchase order") If WinExists('Purchase failed') Or WinExists('Qnt not permitted') Then WinClose('Purchase failed') and WinClose('Purchase order') and WinClose('Qnt not permitted') Else MsgBox(0, 'Text', 'Purchase completed') EndIf When I try to run the script I receive the error: Statement cannot be just an expression - for WinClose('Purchase failed') and WinClose('Purchase order') and WinClose('Qnt not permitted') Can you please suggest a solution?
  28. Let me try #RequireAdmin - the .vbs I'm trying to run isn't one I made myself, unfortunately. It's one of MS's pre-published Office Removal .VBS monstrosities. 3926 lines, more than a minor effort to convert to AutoIt. Happy to provide the file if you're feeling froggy, but it seems effort-prohibitive to me. **Edit - # RequireAdmin didn't change the outcome. Just for grins, used psexec to kick the .exe off under the system account, same issue.
  1. Load more activity