Error

Technical support and scripting issues

Moderators: JRL, Dorian (MJT support)

Post Reply
carlos.carrillo
Newbie
Posts: 3
Joined: Fri Oct 13, 2006 7:51 am

Error

Post by carlos.carrillo » Fri Oct 13, 2006 9:46 am

Hi, I'm using MacroScheduler 8.1 and Beta 9 also in a WinXP computer.

I want MacroScheduler to help to get a .txt file and introduce its content into a webpage.

All the process works fine but in some cases the macro script crashes. The process is as follows:

- I saved a mail into a .txt file from Outlook 2003 using an VBA script and then this script runs a MacroScheduler .exe (my macro script file) file

- I saw that when the mail is written in plain text mode there is no problem, the macro script works fine introducing the information into the wepgage, but...

- when the mail is written in html text mode and saved in .txt my macro script fails with the following:

'Exception EInvalidPointer in module new_ticket.exe at 00002BA0. Invalid pointer operation'

If a open the .txt file with an editor I cannot see any character that can make my script to crash, and I don't see any difference with a saved .txt mail written in plain text mode.

If you want me to send you the scripts and .txt file examples, please tell me...

I hope my information is clear ;-)...

Thanks very much in advance
Carlos

User avatar
Marcus Tettmar
Site Admin
Posts: 7395
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Post by Marcus Tettmar » Fri Oct 13, 2006 10:38 am

Which line causes the error? What results did you get using the debugger? When you run the macro/exe file with logging enabled what does the log file say?
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

carlos.carrillo
Newbie
Posts: 3
Joined: Fri Oct 13, 2006 7:51 am

Post by carlos.carrillo » Mon Oct 16, 2006 8:08 am

Hi, well first I apologize myself for the lack of information... sorry...

well, I'll copy the script, it is not large and will mark in bold the sentence where the error ocurres:

// Generated by MacroScript WebRecorder 1.70
// Recorded on miércoles, agosto 23, 2006, at 10:53 PM
LibLoad>IEAuto.dll,hIE
If>hIE=0
MessageModal>Could not load IEAuto.dll, make sure it is in the path or edit the LibLoad line.
Goto>end_script
EndIf

let>file=c:\test\8.txt
let>summary="hola mundo"

ReadFile>%file%,description

//Move the mouse cursor out of harm's way to avoid causing mouseover events to interrupt
MouseMove>0,0
Let>delay=1
Let>delay2=5

Wait>delay2
LibFunc>hIE,CreateIE,IE[3],0

LibFunc>hIE,Navigate,r,%IE[3]%,http://webpage/newticket.asp
LibFunc>hIE,WaitIE,r,%IE[3]%
Wait>delay

Let>FrameName={""}
Let>FormName={"LoginForm"}
Let>FieldName={"usr_login"}
Let>FieldValue={"user"}
LibFunc>hIE,FormFill,r,%IE[3]%,str:FrameName,str:FormName,str:FieldName,str:FieldValue,0

Let>FrameName={""}
Let>FormName={"LoginForm"}
Let>FieldName={"usr_password"}
Let>FieldValue={"password"}
LibFunc>hIE,FormFill,r,%IE[3]%,str:FrameName,str:FormName,str:FieldName,str:FieldValue,0

Let>FrameName={""}
Let>FormName={"LoginForm"}
Let>TagValue={"new_login"}
LibFunc>hIE,ClickTag,r,%IE[3]%,str:FrameName,str:FormName,INPUT,NAME,str:TagValue

LibFunc>hIE,WaitIE,r,%IE[3]%
Wait>delay

Let>FrameName={""}
Let>FormName={"EditTicket"}
Let>FieldName={"ticket_summary"}
Let>FieldValue={%summary%}
LibFunc>hIE,FormFill,r,%IE[3]%,str:FrameName,str:FormName,str:FieldName,str:FieldValue,0

Let>FrameName={""}
Let>FormName={"EditTicket"}
Let>FieldName={"ticket_description"}
Let>FieldValue={%description%}
LibFunc>hIE,FormFill,r,%IE[3]%,str:FrameName,str:FormName,str:FieldName,str:FieldValue,0

Let>FrameName={""}
Let>FormName={"EditTicket"}
Let>TagValue={"Action"}
LibFunc>hIE,ClickTag,r,%IE[3]%,str:FrameName,str:FormName,INPUT,NAME,str:TagValue

LibFunc>hIE,WaitIE,r,%IE[3]%
Wait>delay2

LibFunc>hIE,KillIE,r,%IE[3]%
Label>end_script

If I use the debugger happens the same problem and in the line in bold:

LibFunc>hIE,ClickTag,r,%IE[3]%,str:FrameName,str:FormName,INPUT,NAME,str:TagValue


I try logging but no info appeared in the log... :(

Thanks and regards,

User avatar
Marcus Tettmar
Site Admin
Posts: 7395
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Post by Marcus Tettmar » Mon Oct 16, 2006 9:05 am

The only way I can debug this is to run through it myself. To do that I would need to know the website URL that you are accessing so that I can run the script. You could email me the URL and login details, or if you prefer not to do that we could organise a remote desktop support session so that I can debug on your machine.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

User avatar
Marcus Tettmar
Site Admin
Posts: 7395
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Post by Marcus Tettmar » Mon Oct 16, 2006 9:07 am

An alternative is to try referencing the Input field using a different attribute. See if the problem is avoided by using ID or INDEX for example, instead of NAME.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

carlos.carrillo
Newbie
Posts: 3
Joined: Fri Oct 13, 2006 7:51 am

Post by carlos.carrillo » Wed Oct 18, 2006 9:51 am

Hi, thanks for the proposal but right now it is not possible to let you enter in our organization as the webpage is hosted in a intranet.

About the hint you provide I tried and didn't worked.

But I quite sure that I can give more detailed information so you will have the opportunity to reproduce the error. Let me contact you later about this.

Thanks very much and regards,
Carlos

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts