Jump to content

Ostap

Members
  • Posts

    15
  • Joined

  • Last visited

Everything posted by Ostap

  1. ; AutoIt Version : 3.3.12.0 ; UDF Version ...: 1.6.2.0 Ok, so installation of newer AutoIT version will solve it?
  2. Moved to new computer, installed AutoIT3 + AD.au3. Checker found below error: "C:\Program Files (x86)\AutoIt3\Include\AD.au3"(5,10) : error: can't open include file <WinAPIConv.au3>. My "include" files: #include <File.au3> #include <FileConstants.au3> #include <GuiConstants.au3> #include <MsgBoxConstants.au3> #include <ProgressConstants.au3> #include <Inet2.au3> #include <Array.au3> #include <String.au3> #include <AD.au3> This is AD.au3 that looks for WinAPIConv.au3. Where can I get WinAPIConv.au3?
  3. /facepalm thanks, works now.
  4. Hi, I want to automate page refreshing in Firefox but script runs for a moment and exits immediately. No msg boxes, no window activation. CLASS value is copied from AutoItWindowInfo. What I've done wrong? #include <MsgBoxConstants.au3> Global $N = 0 HotKeySet ( "{Esc}", Quit() ) While 1 Sleep ( 10000 ) Refresh() WEnd Func Refresh() $ActivateMozilla = WinActivate ( ("[CLASS:MozillaWindowClass]", "" ) If $ActivateMozilla <> 0 Then Send ("{F5}") $N= $N + 1 MsgBox ( 0, "Test", "Refreshed Mozilla " & $N & "times" ) Else MsgBox ( 0, "Error", "Error code " & $ActivateMozilla ) EndIf EndFunc Func Quit() Exit EndFunc
  5. It works. I wanted to delete my post but didn't find how
  6. Hi, I am aiming to add a basic button to Outlook GUI, and now experimenting with OutlookEXGUI. My test script is listing attachments of currently selected e-mail: #include <OutlookEx.au3> #include <OutlookEXGUI.au3> #include <Array.au3> $Outlook = _OL_Open() $Email = _OL_FolderSelectionGet ( $Outlook ) $Attachments = _OL_ItemAttachmentGet ( $Outlook, $Email[1][1] ) _ArrayDisplay ( $Attachments ) _OL_BarGroupAdd ( $Outlook, "Test", 1 ) _OL_Close( $Outlook ) Attachment part works fine, but _OL_BarGroupAdd seem not change anything in the Outllok client (Office 365 ProPLus, build 1902). What I am missing? ================= Found out that it works but I was expecting different output. I wanted to get a group of symbols on the ribbon.
  7. Thanks for suggestions. However, different account are not administrators, just different user account that have access to certain folder on a shared drive. RunAs allows running external program or batch script in Command prompt, not AutoIt function.
  8. Hi, I am writing a long script that among other things, should retrieve list of folders. Sometimes folder access requires different account. I can create query box that would ask for credentials and pass them to the function, but is there a way to run _FileListToArray with different credentials?
  9. Ok, looks like filename is passed as variable %1. Do I simply add something like $PDFFile = EnvGet ( "%1" ) to obtain filename in the script?
  10. Hi, I have a script that extracts maritime container numbers from PDF documents. The script is working fine, however PDF file name is hardcoded into the script. I could of course add some GUI where PDF file can be selected, but I want to make it even easier to use: user select PDF file in Windows Explorer, right click on it and run a script from context menu. Questions: what function to use, in order to detect which file is selected by the user? How to pass file name as variable to the script?
  11. I had been using IBM Personal Communications and Mochasot to connect to mainframe hosts. IBM Personal Communications has built-in macro function and has session parameters saved in .Ws file. If I remember correctly, MochaSoft client also allows to use command line to execute client launch and connect to host.
  12. Sorry for digging out necro topic, but _InetMail is still not capable to send messages when ampersand present in the subject and/or body. This is quite restrictive, wouldn't it be better to include modified Inet.au3 in the distribution?
  13. Clip functions are easy and they work. Full code is too long and not really relevant here, because question is about output formatting. Just to illustrate what I am after, here's the code: #include <Array.au3> Global $Array[1][2] $Cell = "user1 - ok, " & @CRLF & "user2 - disabled, " & @CRLF & "user3 - not found" $Array[0][0] = "Sometext" $Array[0][1] = $Cell _ArrayDisplay ( $Array ) MsgBox ( 0, "", $Cell ) How can I force _ArrayDisplay to show $Array[0][1] as in msgbox?
  14. I have a small script that checks if users from certain security groups exist or are disabled in AD.    For $j = Ubound ( $Users, 1 ) -1 To 0 Step -1       Switch _AD_IsObjectDisabled ( $Users[$j] )           Case 1             ClipPut ( $Users[$j] & " - account disabled; " )           Case 0             If @error = 1 Then                ClipPut ( $Users[$j] & " - account not found; " )             Else                ClipPut ( $Users[$j] & " - Ok; " )             EndIf       EndSwitch    $Clip = $Clip & @CRLF & ClipGet ()    Next   $Data[$O][1] = $Clip The code works correctly, at the end I have a 2D array $Data with security group in column 1 and checked user accounts in columns 2. However, _ArrayDisplay ( $Data ) shows users in one row, despite I added @CRLF. When I write $Clip to a text file, user accounts are written as column. Isn't it possible to have multiple-line cell split by @CRLF in _ArrayDisplay?
  15. Hi, I need to parse a text file extracted from active directory, and string looks like this: CN=Firstname0\, Lastname0 (UserID0),OU=_Marked for deletion,DC=Fabrikam,DC=COM^CN=Firstname1\, Lastname0 (UserID0),OU=Users,OU=EUR,DC=Fabrikam,DC=COM^CN=Firstname2\, Lastname2 (UserID3),OU=Users,OU=EUR,DC=Fabrikam,DC=COM Code is very basic $String0 = "CN=Firstname0\, Lastname0 (UserID0),OU=_Marked for deletion,DC=Fabrikam,DC=COM^CN=Firstname1\, Lastname0 (UserID0),OU=Users,OU=EUR,DC=Fabrikam,DC=COM^CN=Firstname2\, Lastname2 (UserID3),OU=Users,OU=EUR,DC=Fabrikam,DC=COM" MsgBox (0, "$String0", $String0 ) ; returns msgbox with above string $Members = StringSplit ( $String0, "^" ) MsgBox (0, "$Members", $Members ) ; returns empty StringSplit returns empty array no matter what delimiters I try. What I am doing wrong?
×
×
  • Create New...