Vous lisez mes messages et vous faites bien. Le 18/06/08 4:20, umop (Eric) a
écrit :
> Okay. Forget the TextMate example. Just imagine Safari or something
> and a control which isn't given a dictionary reference. A textfield
> or a label which has a value which I'd like to extract. The hugely
> complicated way of doing this would be to snap a picture of the
> application and look at the actual graphical value of the text-field.
> I'm sure that the gui values are available somehow.
What you could try to do is to tell System Events to get that value. BUT
it's not always doable.
Just to help you in that, run the code "tell application "System Events" to
get entire contents of window 1 of the application process "Safari" and
search into the results for the text you wish. If it's not in there, I'm
afraid you won't be able to get it that simply.
Let us know.
--
Jean-Marie
« Priez pour nous, pauvres pécheurs, maintenant et à tout à l'heure »
(«Je vous salue Marie», Gainsbourg)
>> Stay informed about: Extracting text from text control in an application from a..