This is a migrated thread and some comments may be shown as answers.

Reading the Tab Title of a Browser

2 Answers 98 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Nigel
Top achievements
Rank 2
Nigel asked on 14 Feb 2012, 02:29 PM
Hi,

I would like to read the value that appears in the tab of the page I'm viewing in Internet Explorer 9.  For instance, this page I'm looking at now is called "New Forum Thread | Telerik..." (followed by a string defining the thread, etc.).
In my Code Behind window I have this VB sub:

        Public Sub GetTabTitle()
            Dim pageTitle As String = ActiveBrowser.PageTitle
            Log.WriteLine(pageTitle)
        End Sub
I haven't added any Imports so the script just has the default ones.
When I execute my script the log shows:

C:\Users\edwardni\Documents\Test Studio Projects\Base\SystemAdmin\SA_Themes\ValidateThemesScreen.tstest.vb: Line 72: (BC30516) Overload resolution failed because no accessible 'AreEqual' accepts this number of arguments.


Can anywone advise where I am going wrong?

Thanks,
Nigel Edwards, Transition Computing.

2 Answers, 1 is accepted

Sort by
0
Anthony
Telerik team
answered on 14 Feb 2012, 07:10 PM
Hello Nigel,

The page title code is correct. It looks like you're getting a compilation error from another test ("ValidateThemesScreen"). You'll need to resolve the issue in that test directly. See here for more information.

All the best,
Anthony
the Telerik team
Quickly become an expert in Test Studio, check out our new training sessions!
Test Studio Trainings
0
Nigel
Top achievements
Rank 2
answered on 16 Feb 2012, 10:12 AM
Thanks, Anthony.  The issue has been resolved by applying the latest Test Studio upgrade, which allowed me to fix one or two things.  As it happens, I also found an alternative way of doing what I want, without going to the Code Behind window, so everythign is now good.  :)
Tags
General Discussions
Asked by
Nigel
Top achievements
Rank 2
Answers by
Anthony
Telerik team
Nigel
Top achievements
Rank 2
Share this question
or