So let me get this, the AutoInfo does not ID the control when you drag the target icon over the button? If this is the case then you'll need to look at the source of the page and find the reference to the control. You should be able to find it's ID and/or Name. Once you've located this then you can click it.
Hi
Use the Info Tool to identify the handle of the button you wish to click and then use the ControlClick command to click it. I've always found that just passing the function the handle is enough, you don't have to supply all those extra paramaters.
Hope that helps.
Hi taietel
Great script, especially like the technique of embedding the DLL - Well Done!
Now for the silly noobie question..
However, I'm somewhat stumped on exactly how one uses this. I've run the script as is and as expected, the example page has been created. But how do I generate my own page? Is there anyway I can use this create a PDF creation service? I have a requirement where I'd like to take an RTF document and convert it to a PDF.
Thanks
Nope. AFAIK. Best you can do is use the mousemove and mouseclick options. Alternatively run the script within the RDP session which will give you access to the controls.
Yes it would because you're sending keystrokes to a control, in which case the script would halt or stop because the control cannot render. Why don't you try a experiment using Notepad. I think there's code for this in the help. Run the script using a scheduled task making sure you've locked your workstation.
I suppose in a nutshell, if you need to see something in order for the script to work, then it won't work if the workstation is locked. This is my personal experience and so far it's been spot-on!
Hi,
Lookup MouseClick in the help. It describes everything you need to know about clicking the mouse button.
Lookup Send in the help. It describes everything you need to know about sending key presses.
Repeating code can be acheived in many ways. All depends on what you're trying to acheive. Look up Loops in the help.
In a nutshell, Windows suspends all GUI/Keyboard/Mouse activity when a workstation is locked. I've had this issue with all scripts that need to manipulate any GUI. My only workaround has been to run the script in a remote session and lock the workstation. This way the remote session is still being processed while the workstation is securely locked.
If you are running a script on a user's workstation then maybe you can devise a method of checking the PC state. Then you suspend your script if the workstation locked and resume once available. I think somewhere in this forum lies a script that can check if a workstation is locked...you just need to find it.
Good luck.
Hi All,
I've just done an upgrade from v3.2.12.0 to v3.3.6.0 and now my script which worked before is failing to compile. I've gone through the Release notes, in particular those that list the breakages and cannot find this listed. I'm assuming it's called by the Tesseract script because I use some OCR in my script. Can someone help me out with this?
Thanks
Hi,
I kept meaning to post this odd behaviour problem with the ControlSend function before but never got around.
Sometimes, when I send text to a control using ControlSend I get the character that would be generated if the Shift key was pressed or not. For example, just now I sent an address string "80 Streetname" and it posted "8) Streetname". One of my other scripts sends a file path/filname and again the odd time instead of sending "M:\Folder" I get "M;\Folder". I've tried increasing the delay to 500ms and that hasn't really done much. Is there something else that I am missing or can do?
Thanks
That's what I first thought, but then when I tried the ControlSend command that seems to work. I will however try once more as per your suggestion and see if I've missed something.
The syntax I'm using is correct and the values I pass do get sent to the textbox. Problem seems to be that the application I'm controlling isn't setting the value instead just displaying it. I think the application is written in Borland so I don't know if that makes any difference.