Jump to content

rich2323

Active Members
  • Posts

    52
  • Joined

  • Last visited

Everything posted by rich2323

  1. Thank you for finding the solution, it works perfect for my needs. Rich
  2. Change the .pdf extension to open with Adobe Acrobat Standard set as the default. Rich
  3. So I was able to get to my goal, but was hoping to find something that did not rely on using Send command. Local $filepath = "c:\troyit\testpdf.pdf" Local $iPid = Run("explorer.exe /n,/e,/select," & $filepath) ProcessWait($iPid) Send('!{Enter}')
  4. I am trying to launch the files properties of a file in a script. I have tried this but it give me an error. ShellExecute ("C:\Troyit\testpdf.pdf","","","properties" ) Any suggestions? Thanks, Rich
  5. Well, it looks like this VBS script does not work. Anyone else had succuss changing the MAX usage using Autoit? Rich
  6. Hi, So I am trying to setup System Restore on all my Windows 7 machines. System restore was turned off before the imaging process and we now want to turn it back and configure it on each machine. So for I have been able to turn using the following script to turn on System Restore: _SR_Enable("C:\") Func _SR_Enable($DriveL = $SystemDrive) If Not IsObj($obj_SR) Then $obj_SR = ObjGet("winmgmts:{impersonationLevel=impersonate}!root/default:SystemRestore") If Not IsObj($obj_SR) Then Return 0 If $obj_SR.Enable($DriveL) = 0 Then Return 1 Return 0 EndFunc The issue is that when I use the above script, the system is set for 0% MAX disk space use, so I need to change the MAX Usage to 5%. I have found this vbs code, but I am having a hard time converting this to autoit: Const GLOBAL_INTERVAL_IN_SECONDS = 100000 Const LIFE_INTERVAL_IN_SECONDS = 8000000 Const SESSION_INTERVAL_IN_SECONDS = 500000 strComputer = "." Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\default") Set objItem = objWMIService.Get("SystemRestoreConfig='SR'") objItem.DiskPercent = 10 objItem.RPGlobalInterval = GLOBAL_INTERVAL_IN_SECONDS objItem.RPLifeInterval = LIFE_INTERVAL_IN_SECONDS objItem.RPSessionInterval = SESSION_INTERVAL_IN_SECONDS objItem.Put_ Has anyone else configured System Restore ? Thanks, Rich
  7. BrewManNH Right now i do have a TrayMenu item that does have the info in it. The pupose of the tooltip is to quick move over the icon and see what updates are need. All though its messy it does it quickly and without any clicking.
  8. Thakns Firefox, Ill take a look at your code. BrewManNH Thanks for your feedback. I need to display anywhere between 10-400 characters. I want to have the display similar like how the tray tip displays when hovering over the tray icon. I am open to other suggestions. I have an app that need to show availalbe updates when hovering over the icon. Sometimes its 1 item and other it can be 50. Each requiring a line item. 128 characters goes quick. Thanks, Rich
  9. Well, I am feeling pretty stupid at this point, but using TrayGetMsg() I am having the same issue where it continuously displays the message.
  10. guinness, I have looked at the toast option, and was able to get toast to display a message when I have the mouse of the tray icon, but it continually displays the message over and over even when I don't have the mouse over the tray icon any longer. Rich here is my code #include <TrayConstants.au3> ; Required for the $TRAY_EVENT_PRIMARYDOUBLE and $TRAY_EVENT_SECONDARYUP constants. #include <MsgBoxConstants.au3> #include "Toast.au3" Global $sMsg, $hProgress, $aRet[2] Global $sAutoIt_Path = StringRegExpReplace(@AutoItExe, "(^.*\\)(.*)", "\1") Opt("TrayMenuMode", 3) ; The default tray menu items will not be shown and items are not checked when selected. These are options 1 and 2 for TrayMenuMode. Opt("TrayOnEventMode", 1) ; Enable TrayOnEventMode. Example() Func Example() TrayCreateItem("About") TrayCreateItem("") ; Create a separator line. TrayCreateItem("Exit") TrayItemSetOnEvent(-1, "ExitScript") TraySetOnEvent($TRAY_EVENT_PRIMARYDOUBLE, "TrayEvent") TraySetOnEvent($TRAY_EVENT_SECONDARYUP, "TrayEvent") TraySetOnEvent($TRAY_EVENT_MOUSEOVER, "TrayEvent") TraySetState(1) ; Show the tray menu. While 1 Sleep(100) ; An idle loop. WEnd EndFunc ;==>Example Func TrayEvent() Switch @TRAY_ID ; Check the last tray item identifier. Case $TRAY_EVENT_PRIMARYDOUBLE ; Display a message box about the AutoIt version and installation path of the AutoIt executable. MsgBox($MB_SYSTEMMODAL, "", "AutoIt tray menu example." & @CRLF & @CRLF & _ "Version: " & @AutoItVersion & @CRLF & _ "Install Path: " & StringLeft(@AutoItExe, StringInStr(@AutoItExe, "\", 0, -1) - 1)) ; Find the folder of a full path. Case $TRAY_EVENT_SECONDARYUP MsgBox($MB_SYSTEMMODAL, "", "The secondary mouse button was released on the tray icon.") Case $TRAY_EVENT_MOUSEOVER Opt("TrayOnEventMode",0) ConsoleWrite("TESTIJG"& @CRLF) $sMsg = "This Toast uses colours and font defined in a _Toast_Set call." & @CRLF & @CRLF $sMsg &= "Subsequent Toasts will use these values until they are reset by another _Toast_Set call" & @CRLF & @CRLF $sMsg &= "You can also display a standard icon - or one from an exe as here" & @CRLF & @CRLF $sMsg &= "The next Toast has a very small message to show the pre-set minimum size" _Toast_Set(5, 0xFF00FF, 0xFFFF00, 0x0000FF, 0xFFFFFF, 10, "Arial") $aRet = _Toast_Show(@AutoItExe, "User-defined Colours and Bold Header", $sMsg, 5) ConsoleWrite("Toast size: " & $aRet[0] & " x " & $aRet[1] & @CRLF) _Toast_Hide() Sleep (2000) Opt("TrayOnEventMode",1) EndSwitch EndFunc ;==>TrayEvent Func ExitScript() Exit EndFunc ;==>ExitScript
  11. Tooltip is limited to 128 characters. What other options do I have to display over 128 characters when the mouse is over the tray icon like tooltip does? Rich
  12. Thank you very much works like a charm! Rich
  13. Is there a way to check to see if a iphone or ipad is connect to usb using Autoit? Rich
  14. Has anyone else had any issues with this script since filehippo updated their website? Rich
  15. So for now I got around the issue by extracting the msi and cab files, then running the the msi silently to install. Its not optimal since there is not an easy way to extract the files from the executable but it will have to do for now. Thanks, Rich
  16. Hi Jlogan3o13, Thanks for your reply. I am using the Primasoft RunAsSvc , which I believe uses the "local system" account to run. The files for install are located locally in a directory called "C:troyitAutoInstallerjava" . The everyone group has access to this location. The 64bit version works just fine. The website I linked above, gives more details of the issue and why its happening. Here is a quick blurb from the website that explains it a bit better than I could. I was just hoping that someone already tackled this issue and could point me in the right direction. Rich
  17. Has anyone had any success installing 32 bit Java on Win7 (64bit) using a Windows Service (Primasoft RunAsSvc)? When trying to run, I am getting an 1619 error. The 64 bit version works fine using this same method. If I run the same script as a user, the 32bit installs succesfully. I have found some info on this website, but I have been unable to get it to work: https://harryjohnston.wordpress.com/2011/02/20/installing-32-bit-software-as-system-in-windows-7-x64/#comment-409 Here is the command I am running for the install: ;; 64bit If @OSArch = "x64" then RunWait('C:\troyit\AutoInstaller\java\JavaInstall64.exe /s /L C:\TROYIT\AutoInstaller\java\JavaDeployLog-64.txt') ;; 32bit RunWait('C:\troyit\AutoInstaller\java\JavaInstall32.exe /s /L C:\TROYIT\AutoInstaller\java\JavaDeployLog-32.txt') Any help would be greatly appricated! Thanks, Rich
  18. I think i figured it out. I had to add the -s parameter to the command line psexec 192.168.1.148 -f -c -i -s "C:guictrlcreatebutton.exe" Not sure why this is the case, but it solved my issue. Thanks, Rich
  19. K, I just wanted to be sure that there were not any compatibility issues before I dug in to deep. I am just using the guictrlcreatebutton script in the help files. The script executes, its just not displaying properly, I am guessing this is a psexec issue rather than an autoit issue. Here is the command line I am using. psexec 192.168.1.148 -f -c -i "C:guictrlcreatebutton.exe"
  20. I am trying to run a simple GUI (I used the GUICtrlCreateButton.au3 in the help files) using PSexec, and when I run the complied script, the GUI is there but the labels and buttons are not visable (the whole gui is black). If I run the same script locally on the machine it displays properly. I am running the script as an Admin both locally and through PSexec. Is there some sort of incompatibility with Autoit and PSexec? Has anyone else seen this behavior? Does anyone have any suggestions on how to work around this issue? Thanks, Rich
  21. Thanks Triprdacus, I was banging my head on this one and could not figure it out. I'll start working on plan B. I really appreciate that you help explain why it does not work, rather than just leaving it hanging out there. It’s nice to have closure. Rich
  22. I am trying to remotely remove a HKU registry key. I can delete values in the same branch, but can't delete the actual key. I also can delete the key if I use the registry editor (connecting remotely) Here is an example of the registry key exported: Windows Registry Editor Version 5.00 [HKEY_USERS\S-1-5-21-1400463981-1064451746-3237261625-5047\Software\Act\OutlookAddressBooks] [HKEY_USERS\S-1-5-21-1400463981-1064451746-3237261625-5047\Software\Act\OutlookAddressBooks\2] "padFile"="" "Password"="F180D8541454E04F8C1EC942F86A588B" "User"="" Here is the code I use to delete "padFile" from OutlookAddressBooks\2 $delete = RegDelete ("\\192.168.16.101\HKU\S-1-5-21-1400463981-1064451746-3237261625-5047\Software\Act\OutlookAddressBooks\2","PadFile") This code works correctly and deletes the value. Here is the code I am trying to use to delete OutlookAddressBooks\2: $delete = RegDelete ("\\192.168.16.101\HKU\S-1-5-21-1400463981-1064451746-3237261625-5047\Software\Act\OutlookAddressBooks\2") When I run this code I get a return code of "2" and an @error code of "-2" and an extended error code of "1745" Am I doing something wrong in my code? Is there a better way to delete this remotely? Thanks for your help, Rich
  23. I changed the code to a generic website name....is that more appropriate?
  24. Sorry, I was not aware of this rule, I am just trying to under autoit better. I will delete my post. How can I learn autoit if I can use it for practical purposes? I think your being a little harsh. Thanks anyways. Rich
×
×
  • Create New...