How to get page title name while sikuli script running

Asked by basha

Hi Team,
Please solve the below question as i am not getting title name of the open page.

How to get page title name while sikuli script running?

Ex:if i opened a google page,i need to see the titile of the page.

Thanks&Regards,
Basha

Question information

Language:
English Edit question
Status:
Answered
For:
SikuliX Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
obiwan-92 (obiwan-92) said :
#1

Hello.

Today, I'm afraid there is no such function in Sikuli.
The simply workaround will be to get the address in the address bar with the following code
doubleClick("address_bar.png")
type('c', KeyModifier.CTRL)
address = Env.getCilipboard()
if 'google' in address:
    print 'It is google page'
else:
    print 'it is not a google page'

Hope, it's help.
Regards.

Can you help with this problem?

Provide an answer of your own, or ask basha for more information if necessary.

To post a message you must log in.