After starting, there was a complaint about
no module SendKeys.
It would be helpful to mention it to install somewhere.
So I fired up google and found it in:
with Pycrust, I tried your example.
Here is the output:
>>> app = application.Application()
<application.Application object at 0x01F9CE30>
Traceback (most recent call last):
File "<input>", line 1, in ?
File "C:\Python24\Lib\site-packages\application.py", line 142, in __getattr__
dlg, final = wait_for_function_success(
File "C:\Python24\Lib\site-packages\application.py", line 169, in wait_for_function_success
return func(*args, ** kwargs)
File "C:\Python24\Lib\site-packages\application.py", line 111, in WalkDialogControlAttribs
dialogWin = findbestmatch.find_best_control_match(attr_path, wins)
File "C:\Python24\Lib\site-packages\findbestmatch.py", line 209, in find_best_control_match
raise MatchError(items = name_control_map.keys(), tofind = search_text)
MatchError: Could not find 'Notepad' in '[u'UnbenanntEditorDialog', u'UnbenanntEditor', 'Dialog']'
Sorry I missed you message before - I didn't see this area.
The problem is that you are on German windows so when Notepad starts up it doesn't have the title "Untitled - Nodepad" but "Unbenannt - Editor". So you would have to modify the script to say Editor.
In the near future I would like to modify the script so that you can save information once and it will use that information to find the dialog. That will be easy enough for controls - but not so easy for dialogs (I need to think how to do this!)
I will add a ticket (bug report) that I need to mention that for now the test_application.py only runs well on English.
Log in to post a comment.
Sign up for the SourceForge newsletter:
You seem to have CSS turned off.
Please don't fill out this field.