Clicktag problem

Technical support and scripting issues

Moderators: JRL, Dorian (MJT support)

Post Reply
Liberty
Pro Scripter
Posts: 56
Joined: Wed Jun 06, 2007 11:56 am
Location: Sweden

Clicktag problem

Post by Liberty » Fri Feb 24, 2012 12:44 pm

I have several problems with Clicktag.
Sometimes a script is working, somtimes both the script AND MacroScheduler hang.
To continue I have to stop MacroSscheduler by the Windows Taskmanager and restart. This is rather frustrating as the script is scheduled to start at night and the following scripts are then not running at all.

I have tried a lot of different things.
The code is trivial and the log gives nothing:

Wait>%Delay%
SetFocus>%xpage%
WaitReady>0
Let>FrameName={""}
Let>FormName={""}
Let>TagValue={"Main session"}
WaitReady>0
LibFunc>hIE,ClickTag,r,%IE [0]%,str:FrameName,str:FormName,A,TEXT,str:TagValue
Wait>%Delay%
WaitReady>0

What to do?
(I could email the the complete code separately - give then the email address)
Could I detect the hanging and do something about it?

I use 12.1.10

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 Feb 24, 2012 5:32 pm

Most likely scenario is that the tag doesn't exist yet.

WaitReady will do nothing. It will not help with IE/WebRecorder scripts. You should use IE_Wait and Wait instead.

WR3 is better as it has WaitDocumentComplete function. Also WaitForText function so you have better ways of waiting. It also includes timeouts and will automatically wait until the tag you want to click exists before attempting to click it (or timing out depending on the timeout setting).
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

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

Liberty
Pro Scripter
Posts: 56
Joined: Wed Jun 06, 2007 11:56 am
Location: Sweden

Post by Liberty » Fri Feb 24, 2012 7:21 pm

Thank you very much.

I will try but:

Where do I find descriptions for WR3, WaitFor etc?

(The "Main Session" tag appears immediately in the window, btw. Delay is now 4)

Liberty
Pro Scripter
Posts: 56
Joined: Wed Jun 06, 2007 11:56 am
Location: Sweden

Post by Liberty » Tue Mar 06, 2012 5:20 pm

No reply to my important question.

Where can I find descriptions of the functions Marcus has teased(?) me with?

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

Post by Marcus Tettmar » Tue Mar 06, 2012 6:02 pm

By WR3 I was referring to WebRecorder 3.0. And the functions I mentioned are functions provided by the WebRecorder 3.0 runtime. The documentation for them is in the WebRecorder 3.0 help file.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

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

Liberty
Pro Scripter
Posts: 56
Joined: Wed Jun 06, 2007 11:56 am
Location: Sweden

Post by Liberty » Thu Mar 08, 2012 9:03 pm

Thank you Marcus.

I did not know about WebRecorder 3, which is not included in the maintenance.

I will read about this program.

I have now used WaitPixelColor and it seems that this will solve the problem as well as for another case where I get Integer Overflow in a lot of small windows popping up at each second all over the screen - which is very irritating as there is also a sound coming from Windows as an error signal. In this latter case Task Manager has to be used to stop the process of windows popping up. In this case I use FindImagePos and LClick - probably also too early.

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