Difficulty in getting window text of control panel in xp64

Technical support and scripting issues

Moderators: Dorian (MJT support), JRL

Post Reply
jiby
Junior Coder
Posts: 30
Joined: Fri Feb 26, 2010 12:26 pm

Difficulty in getting window text of control panel in xp64

Post by jiby » Wed Jul 07, 2010 4:47 pm

hi,

I am using XP64. My code is

Run>control
WaitWindowOpen>Control Panel
SetFocus>Control Panel
Wait>2
GetWindowTextEx>Control Panel,str
Message>str

The output of str is NOTHING.
I replaced 'GetWindowTextEx' with 'GetWindowText'. Then the output is 'Internet Explorer'

I could see the same when extracting text in 'Add or Remove Programs' using 'appwiz.cpl'

Please suggest a way to get the window displayed on the 'Control Panel'

Thanks
jiby

User avatar
JRL
Automation Wizard
Posts: 3518
Joined: Mon Jan 10, 2005 6:22 pm
Location: Iowa

Post by JRL » Wed Jul 07, 2010 8:14 pm

Copying from your post I got a space at the end of the line:

Message>str

If there is a space in your actual code you'll never see anything but "str". You could alleviate any possibility that is the case by placing percents around "str"

Message>%str%

If you are getting a completely blank message, that would indicate the variable is getting set to nothing.

I'm running win XP 32 and have no 64 to test with but I would comment that your script works fine for me. However, there does seem to be a lot of blank space at the top of the message... is it possible that if you scroll down there will be text that is not visible on your first opening the message window?

adroege
Automation Wizard
Posts: 438
Joined: Tue Dec 07, 2004 7:39 pm

Post by adroege » Wed Jul 07, 2010 8:40 pm

Is this the same issue?

http://www.mjtnet.com/forum/viewtopic.php?t=6274


At the end of the previous post, it was mentioned by mtettmar to use a loop to retrieve the text

jiby
Junior Coder
Posts: 30
Joined: Fri Feb 26, 2010 12:26 pm

Post by jiby » Thu Jul 08, 2010 7:01 am

Hi,

> The space after 'str' is typo error. I am not getting str either. Its complete blank.

> http://www.mjtnet.com/forum/viewtopic.php?t=6274
In the above post, I was referring to partial text in the window.

> In xp32, I could get the text. But I am getting nothing in xp64.

Please provide any alternative.

Thanks
jiby

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

Post by Marcus Tettmar » Thu Jul 08, 2010 8:54 am

Hi,

The following commands currently cannot retrieve text from 64 bit processes:

GetTextInRect
GetTextAtPoint
GetWindowTextEx

These use the provided text capture library which works by "hooking" into other processes in order to monitor their "Text Out" calls. I have been told that a 64 bit solution is in the works.

These functions DO work with 64 bit processes:

GetWindowText
GetControlText
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

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

jiby
Junior Coder
Posts: 30
Joined: Fri Feb 26, 2010 12:26 pm

Post by jiby » Fri Jul 09, 2010 10:59 am

Hi mtettmar,

Thanks for confirming this.

I am trying with GetControlText. The objects of 'control panel' viewed in 'View System Windows' when I used with GetControlText, resulted in '##NOSUCHOBJECT##'. Please tell, if there is anyway.

Thanks
jiby

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