sbrady Posted December 18, 2012 Share Posted December 18, 2012 here is the result of running the script. Outlook is NOT open when I run the script. I am not sure where things are going wrong.>"C:Program FilesAutoIt3SciTE..autoit3.exe" /ErrorStdOut "C:Documents and SettingssebradDesktopshawnOutlook Scripts EX_OL_ItemCreate_SB.au3"COM Error Encountered in _OL_ItemCreate_SB.au3OutlookEx UDF version = 0.9.0@AutoItVersion = 3.3.8.1@AutoItX64 = 0@Compiled = 0@OSArch = X86@OSVersion = WIN_XPScriptline = 1205NumberHex = 80010108Number = -2147417848WinDescription = The object invoked has disconnected from its clients.Description = Source = HelpFile = HelpContext = 0LastDllError = 0========================================================COM Error Encountered in _OL_ItemCreate_SB.au3OutlookEx UDF version = 0.9.0@AutoItVersion = 3.3.8.1@AutoItX64 = 0@Compiled = 0@OSArch = X86@OSVersion = WIN_XPScriptline = 1435NumberHex = 80010108Number = -2147417848WinDescription = The object invoked has disconnected from its clients.Description = Source = HelpFile = HelpContext = 0LastDllError = 0========================================================C:Program FilesAutoIt3IncludeOutlookEX.au3 (1438) : ==> Error in expression.:Local $oInbox = $oNamespace.GetDefaultFolder($olFolderInbox)Local $oInbox = ^ ERROR>Exit code: 1 Time: 4.757 Link to comment Share on other sites More sharing options...
water Posted December 18, 2012 Author Share Posted December 18, 2012 Does the specified folder "*\Outlook-UDF-Test\TargetFolder\Mail" exist? $oItem = _OL_ItemCreate($oOutlook, $olMailItem, "*\Outlook-UDF-Test\TargetFolder\Mail", "", "Subject=TestMail", "BodyFormat=" & $olFormatHTML, _ "HTMLBody=Bodytext in [b]bold[/b]") 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 Link to comment Share on other sites More sharing options...
sbrady Posted December 18, 2012 Share Posted December 18, 2012 I am a Mac user...........am I looking in C:........program files?..........my documents?..........where Link to comment Share on other sites More sharing options...
sbrady Posted December 18, 2012 Share Posted December 18, 2012 is this a folder in Outlook??? Link to comment Share on other sites More sharing options...
water Posted December 18, 2012 Author Share Posted December 18, 2012 Correct, this is a folder in Outlook. When you run your example script do you get message "Testenvironment already exists. Should it be deleted and recreated?" If yes, do you click YES, NO or CANCEL? 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 Link to comment Share on other sites More sharing options...
sbrady Posted December 18, 2012 Share Posted December 18, 2012 "Testenvironment already exists. Should it be deleted and recreated?" If yes, do you click YES, NO or CANCEL? yup, that is what I get, I click yes......delete and recreate.......but I dont see that folder structure anywhere Link to comment Share on other sites More sharing options...
water Posted December 18, 2012 Author Share Posted December 18, 2012 Could you please remove all "Outlook-UDF-Test" folders from your "Deleted items" folder and re-run the script? 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 Link to comment Share on other sites More sharing options...
sbrady Posted December 18, 2012 Share Posted December 18, 2012 I deleted all items in the deleted items icon in Outlook, I also deleted the recycle bin. Running the script still tells me Testenvironment already exists. Link to comment Share on other sites More sharing options...
water Posted December 18, 2012 Author Share Posted December 18, 2012 That's fine. But when you then click YES the currently existing test environment should be deleted and a new one created. Your script should then create the mail item just fine (at least I hope so). 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 Link to comment Share on other sites More sharing options...
sbrady Posted December 18, 2012 Share Posted December 18, 2012 so when I click yes, I should see a folder called "Outlook-UDF-Test" in the Mail Items list.........next to "Drafts"......"Inbox"......"Outbox"....."Sent Items".......etc. I dont see the folder so cant I just make a folder with that name. Link to comment Share on other sites More sharing options...
sbrady Posted December 18, 2012 Share Posted December 18, 2012 I got a test appointment pop up window...........arent we making an outgoing email.......thats my goal. Link to comment Share on other sites More sharing options...
water Posted December 18, 2012 Author Share Posted December 18, 2012 That's OK too. The testenvironment is created with a lot of test items - including a test appointment. Does your script still crash? 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 Link to comment Share on other sites More sharing options...
water Posted December 18, 2012 Author Share Posted December 18, 2012 so when I click yes, I should see a folder called "Outlook-UDF-Test" in the Mail Items list.........next to "Drafts"......"Inbox"......"Outbox"....."Sent Items".......etc.I dont see the folder so cant I just make a folder with that name.You click on the folders icon - or Ctrl+6 - to display all folders and you will see a "Outlook-UDF-Test" folder. 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 Link to comment Share on other sites More sharing options...
sbrady Posted December 18, 2012 Share Posted December 18, 2012 OK I see it.........but doesnt the script just make a reminder or calendar event.......the icon is a calendar........how do I get it to make a new outgoing email with a recipient, subject and body. Link to comment Share on other sites More sharing options...
water Posted December 18, 2012 Author Share Posted December 18, 2012 Does your script still crash? If not, I will tell you where to find the created mail 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 Link to comment Share on other sites More sharing options...
sbrady Posted December 18, 2012 Share Posted December 18, 2012 Ok I open the SourceFolder or TargetFolder, I see an email in the yellow Mail folder........great.......is it possible to: 1. put someones email address in the To: field. 2. remove the attachment. 3. put in my own subject title 4. put the text I want in the body. I think we are almost there. Link to comment Share on other sites More sharing options...
water Posted December 18, 2012 Author Share Posted December 18, 2012 If your test script ran successfully you should find a mail in folder "Outlook-UDF-TestTargetFolderMail" with todays date and subject "TestMail". Is it there? 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 Link to comment Share on other sites More sharing options...
sbrady Posted December 18, 2012 Share Posted December 18, 2012 well.......an email is there......there is no date. Subject says ""TestMail". The body of the email says Bodytext in bold. There is an attachment which is nice but I do not need for my purposes. I think I can use in input box to get text and put that in the script. How or where do I add a recipient. Thanks. Link to comment Share on other sites More sharing options...
water Posted December 18, 2012 Author Share Posted December 18, 2012 Does your example script create an attachment ... NO, if you use the code you previously posted. So the mail you see with an attachment can't be the mail created by your script. Any other mails in this folder? 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 Link to comment Share on other sites More sharing options...
sbrady Posted December 18, 2012 Share Posted December 18, 2012 I deleted the 2 emails in the SourceFolder and TargetFolder. Then I ran the script. I got a new email with NO attachment, NO name in the TO: where in the script do I add a recipient. Link to comment Share on other sites More sharing options...
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