Jump to content



Photo

need help getting controltext


  • Please log in to reply
4 replies to this topic

#1 erezlevi

erezlevi

    Universalist

  • Active Members
  • PipPipPipPipPipPip
  • 436 posts

Posted 03 December 2008 - 04:35 PM

hi,

I need help with getting the control text from the following window:

Attached is a file with a screen shot of the controlwindow.

thanks,

I tried :

$m=WinGetText ("[CLASS:AfxWnd70u]","") --> dosen't work.

also: ControlGetText ("Customer Interaction Express","","[CLASSNN....) didn't work also.

please help me out.





#2 big_daddy

big_daddy

  • Moderators
  • 2,499 posts

Posted 03 December 2008 - 05:50 PM

You're trying to use the class of the control to get reference to the window, that obviously won't work.

$sText = ControlGetText("Customer Interaction Express", "", "[CLASSNN:AfxWnd70u36]") ConsoleWrite($sText & @CR)

BD Scripting - My scripting repository.AutoIt Menu - Firefox extension with several links and tools for the AutoIt Forums!AutoIt Snippets Database - Store and share all your favorite snippets here! Welcome to AutoIt 1-2-3 - Great starting place for newcomers.Learning to Script with AutoIt - Another good starting place for newcomers.SciTE - The best AutoIt Script Editor. Posted Image

#3 erezlevi

erezlevi

    Universalist

  • Active Members
  • PipPipPipPipPipPip
  • 436 posts

Posted 03 December 2008 - 06:07 PM

You're trying to use the class of the control to get reference to the window, that obviously won't work.

$sText = ControlGetText("Customer Interaction Express", "", "[CLASSNN:AfxWnd70u36]") ConsoleWrite($sText & @CR)

hi, Thanks, I will try it tomorrow and let you know if it worked.

#4 erezlevi

erezlevi

    Universalist

  • Active Members
  • PipPipPipPipPipPip
  • 436 posts

Posted 04 December 2008 - 09:23 AM

hi, again.

I still have a problem, allthough this works, the second time you open the application, it has a different CLASSNN number for this control.

pls help out.

is there any way to get the CLASSNN of a CLASS control before getting the data like guictrlgetclassNN ? because the CLASS itself AfxWnd70u never changes only the CLASSNN.

#5 Zedna

Zedna

    AutoIt rulez!

  • MVPs
  • 8,315 posts

Posted 04 December 2008 - 12:22 PM

hi, again.

I still have a problem, allthough this works, the second time you open the application, it has a different CLASSNN number for this control.

pls help out.

is there any way to get the CLASSNN of a CLASS control before getting the data like guictrlgetclassNN ? because the CLASS itself AfxWnd70u never changes only the CLASSNN.

Looks which of other properties of that control don't change (for example: X,Y,W,H) and specify it in your
[CLASS:AfxWnd70u; X:100; Y:200]

Edited by Zedna, 04 December 2008 - 12:23 PM.





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users