Katharsis Posted April 10, 2012 Posted April 10, 2012 (edited) ...or maybe with the way it now communicates with CDO.DropDirectory.We have a script that monitors e-mails that come in to a drop directory. The script looks at the e-mails and sends a response accordingly to the user that sent the e-mail. However, after updating to the latest AutoIt, I cannot compile due to a supposed syntax error which does not exist.Here is the relevant code:$objDropDirectory = ObjCreate("CDO.DropDirectory") $colMessageCollection = $objDropDirectory.GetMessages($DropFolder) If $colMessageCollection.Count > 0 Then For $msg In $colMessageCollection $fileFullPath = $colMessageCollection.Filename($msg) If StringInStr($msg.To, "daily", 2) Then ...do stuff... EndIf Next EndIfThe error I receive upon compiling is this:(36,26) : ERROR: missing separator character after keyword. If StringInStr($msg.To,Clearly, there is a separator character. The comma is right there. This wasn't happening before 3.3.8.x. Any ideas? Edited April 10, 2012 by Katharsis
ProgAndy Posted April 10, 2012 Posted April 10, 2012 (edited) Is this error from Au3Check or from the compiler? If possible try to ignore it. What happens if you add a space after .To? Propably Au3Check messes up since To is a keyword when using the for-loop. Edited April 10, 2012 by ProgAndy *GERMAN* [note: you are not allowed to remove author / modified info from my UDFs]My UDFs:[_SetImageBinaryToCtrl] [_TaskDialog] [AutoItObject] [Animated GIF (GDI+)] [ClipPut for Image] [FreeImage] [GDI32 UDFs] [GDIPlus Progressbar] [Hotkey-Selector] [Multiline Inputbox] [MySQL without ODBC] [RichEdit UDFs] [SpeechAPI Example] [WinHTTP]UDFs included in AutoIt: FTP_Ex (as FTPEx), _WinAPI_SetLayeredWindowAttributes
Developers Jos Posted April 10, 2012 Developers Posted April 10, 2012 What version of AU3check you are getting this warning from as the current Beta doesn't give this error for me with the posted snippet. SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
KaFu Posted April 10, 2012 Posted April 10, 2012 (edited) AU3Check (1.54.22.0) throws the same error message for me too. Maybe just change $msg.To to $msg.To()? Edited April 10, 2012 by KaFu OS: Win10-22H2 - 64bit - German, AutoIt Version: 3.3.16.1, AutoIt Editor: SciTE, Website: https://funk.eu AMT - Auto-Movie-Thumbnailer (2024-Oct-13) BIC - Batch-Image-Cropper (2023-Apr-01) COP - Color Picker (2009-May-21) DCS - Dynamic Cursor Selector (2024-Oct-13) HMW - Hide my Windows (2024-Oct-19) HRC - HotKey Resolution Changer (2012-May-16) ICU - Icon Configuration Utility (2018-Sep-16) SMF - Search my Files (2025-May-18) - THE file info and duplicates search tool SSD - Set Sound Device (2017-Sep-16)
Katharsis Posted April 10, 2012 Author Posted April 10, 2012 The parentheses fixed it. Thanks! Also, the Au3Check is version 1.54.22.0.
Moderators Melba23 Posted April 10, 2012 Moderators Posted April 10, 2012 Katharsis,This was covered in the v3.3.8.0 changelog: "Changed: Parentheses are required when invoking objects after all method names in order to have correct internal handling"Always worth a look in there when you upgrade. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area
trancexx Posted April 10, 2012 Posted April 10, 2012 (edited) How would AU3Check know if .To is method or property?This has nothing to do with that. This was a bug in AU3Check where it was confusing AutoIt's keywords and object prop/methods. It was fixed some time ago.It's wrong to use parentheses here. Edited April 11, 2012 by trancexx ♡♡♡ . eMyvnE
lsakizada Posted November 3, 2014 Posted November 3, 2014 I have instaled today latest autoit (Scite 14.01.22.21, AU3 v3.3.12.0, Beta v3.3.13.19) and encounter the same issue. I added parentheses to the method name and this not help to rsolve the error: Here is the error and the function (from SMTP UDF): >Running AU3Check (3.3.12.0) from:C:\Program Files (x86)\AutoIt3 input:C:\Automation\tmp\UI7.au3 "C:\Automation\tmp\includes\OnAutoItErrorRegister.au3"(565,15) : error: missing separator character before keyword. $objEmail.To ~~~~~~~~~~~~~~^ "C:\Automation\tmp\includes\mailer.au3"(33,15) : error: missing separator character before keyword. $objEmail.To ~~~~~~~~~~~~~~^ Func __OnAutoItErrorRegister_INetSmtpMailCom($s_SmtpServer, $s_FromName, $s_FromAddress, $s_ToAddress, $s_Subject = "", $s_Body = "", $s_CcAddress = "", $s_BccAddress = "", $s_Username = "", $s_Password = "", $IPPort = 25, $ssl = 0) Local $objEmail = ObjCreate("CDO.Message") If Not IsObj($objEmail) Then Return SetError(1, 0, 0) $objEmail.From = '"' & $s_FromName & '" <' & $s_FromAddress & '>' $objEmail.To = $s_ToAddress Local $i_Error = 0 Local $i_Error_desciption = "" If $s_CcAddress <> "" Then $objEmail.Cc = $s_CcAddress If $s_BccAddress <> "" Then $objEmail.Bcc = $s_BccAddress What am I supposed to do to resolve this issue? Thanks Be Green Now or Never (BGNN)!
water Posted November 3, 2014 Posted November 3, 2014 Install the latest Beta version of AutoIt. My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki
lsakizada Posted November 4, 2014 Posted November 4, 2014 (edited) Install the latest Beta version of AutoIt. I did it and mentioned the version in my previous post. It is 3.3.13.19. Downloaded from here: https://www.autoitscript.com/autoit3/files/beta/autoit/ It is not working. Thanks Edited November 4, 2014 by lsakizada Be Green Now or Never (BGNN)!
water Posted November 4, 2014 Posted November 4, 2014 Sorry, missed that This >bug has been reported a few times and the latest beta always resolved the issue. My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki
lsakizada Posted November 4, 2014 Posted November 4, 2014 Sorry, missed that This >bug has been reported a few times and the latest beta always resolved the is Is there any chance that the bug was inserted in the latest beta again? As much as I understood this is a bug of AU3Check, maybe this tool is still buggy? Regards Be Green Now or Never (BGNN)!
water Posted November 4, 2014 Posted November 4, 2014 DIdn't have this problem myself. But it seems that the latest beta solved the problem for the other users. My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki
lsakizada Posted November 4, 2014 Posted November 4, 2014 (edited) Hi Water, thanks for the reply. Anyway, I reinstall and install the all Autoit components several times with different options for 32/64 bit and made sure the installation folder is clean but, the error still exists. I think it is a bug that was not resolved completely. Edited November 4, 2014 by lsakizada Be Green Now or Never (BGNN)!
water Posted November 4, 2014 Posted November 4, 2014 When I run the SciTE "SyntaxCheck Prod" tool for your code I get the same error. When I run the SciTE "SyntaxCheck Beta" tool for your code I get no error. Beta = 3,3.13.19 You are sure you run the Beta version? Can you post the Scite output? My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki
BrewManNH Posted November 4, 2014 Posted November 4, 2014 The problem isn't in AutoIt, it's in Au3Check and has been fixed in the latest version of that tool. If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag GudeHow to ask questions the smart way! I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from. Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays. - ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script. - Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label. - _FileGetProperty - Retrieve the properties of a file - SciTE Toolbar - A toolbar demo for use with the SciTE editor - GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI. - Latin Square password generator
water Posted November 4, 2014 Posted November 4, 2014 But Au3Check is part of the AutoIt download as described in post #10, isn't it? I suspect the OP has installed the latest beta, but doesn't run the SyntaxCheck Beta. My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki
lsakizada Posted November 9, 2014 Posted November 9, 2014 (edited) When I run the SciTE "SyntaxCheck Prod" tool for your code I get the same error. When I run the SciTE "SyntaxCheck Beta" tool for your code I get no error. Beta = 3,3.13.19 You are sure you run the Beta version? Can you post the Scite output? This is the output: Look like it is indeed running the AU3Check (3.3.12.0). How come? BTW: The Compiler is running the same version AU3Check (3.3.12.0). In the compiler: Running Beta + "Run AU3Check before compilation" checkbox is checked BUT the AU3Check version is still kept AU3Check (3.3.12.0). EDIT: There is a little bug in the presentation of the AU3Check (3.3.12.0). Its corrected itself after running as beta and restarting the UI. I think my issue is resolved. >"C:\Program Files (x86)\AutoIt3\SciTE\AutoIt3Wrapper\AutoIt3Wrapper.exe" /run /prod /ErrorStdOut /in "C:\Automation\tmp\UI7.au3" /UserParams +>08:30:43 Starting AutoIt3Wrapper v.14.801.2025.0 SciTE v.3.4.4.0 Keyboard:00000409 OS:WIN_7/Service Pack 1 CPU:X64 OS:X64 Environment(Language:0409) +> SciTEDir => C:\Program Files (x86)\AutoIt3\SciTE UserDir => C:\Users\bik\AppData\Local\AutoIt v3\SciTE\AutoIt3Wrapper SCITE_USERHOME => C:\Users\bik\AppData\Local\AutoIt v3\SciTE >Running AU3Check (3.3.12.0) from:C:\Program Files (x86)\AutoIt3 input:C:\Automation\tmp\UI7.au3 "C:\Automation\tmp\includes\OnAutoItErrorRegister.au3"(566,12) : error: missing separator character before keyword. $objEmail.To ~~~~~~~~~~^ "C:\Automation\tmp\includes\mailer.au3"(33,15) : error: missing separator character before keyword. $objEmail.To ~~~~~~~~~~~~~~^ C:\Automation\tmp\UI7.au3 - 2 error(s), 0 warning(s) !>08:30:44 AU3Check ended. Press F4 to jump to next error.rc:2 +>08:30:44 AutoIt3Wrapper Finished. >Exit code: 2 Time: 1.458 Edited November 9, 2014 by lsakizada Be Green Now or Never (BGNN)!
water Posted November 9, 2014 Posted November 9, 2014 Great. I knew the problem would be solved by using the correct version of Au3Check. My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki
Jefrey Posted July 1, 2015 Posted July 1, 2015 (edited) Sorry for posting on a 3 years old post, but 3 years later this bug seems not to have been fixed on the production version...I can't use properties that have names like keywords (I'm having the exact problem, the property name is also 'To').Luckly, I'm developing the object, so I'm able to change the "To" property name to something else. Do I still need to use Beta version to have the fix? Edited July 1, 2015 by Jefrey My stuff Spoiler My UDFs _AuThread multithreading emulation for AutoIt · _ExtInputBox an inputbox with multiple inputs and more features · forceUTF8 fix strings encoding without knowing its original charset · JSONgen JSON generator · _TCPServer UDF multi-client and multi-task (run on background) event-based TCP server easy to do · _TCPClient_UDF multi-server and multi-task (runs on background) event-based TCP client easy to do · ParseURL and ParseStr functions ported from PHP · _CmdLine UDF easily parse command line parameters, keys or flags · AutoPHP Create documents (bills, incomes) from HTML by sending variables/arrays from AutoIt to PHP · (Un)Serialize Convert arrays and data into a storable string (PHP compatible) · RTTL Plays and exports to MP3 Nokia-format monophonic ringtones (for very old cellphones) · I18n library Simple and easy to use localization library · Scripting.Dictionary OOP and OOP-like approach · Buffer/stack limit arrays to N items by removing the last one once the limit is reached · NGBioAPI UDF to work with Nitgen fingerprint readers · Serial/Licensing system require license key based on unique machine ID from your users · HTTP a simple WinHTTP library that allows GET, POST and file uploads · Thread true AutoIt threads (under-dev) · RC4 RC4 encryption compatible with PHP and JS · storage.au3 localStorage and sessionStorage for AutoIt Classes _WKHtmlToX uses wkhtmlto* to convert HTML files and webpages into PDF or images (jpg, bmp, gif, png...) Snippets _Word_DocFindReplaceByLongText replace strings using Word UDF with strings longer than 255 characters (MSWord limit) rangeparser parser for printing-like pages interval (e.g.: "1,2,3-5") EnvParser parse strings/paths with environment variables and get full path GUICtrlStaticMarquee static text scrolling Random stuff Super Mario beep sound your ears will hurt
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now