Thanks for sreekanth chilam
CreationTime:=0 only identifies the first browser in a desktop instead of the top browser except that there is only one browser in a desktop.
I do it in another similar way. First calculate the total no of the browsers, then the top browser is the CreationTime:=total-1. I don't know whether there is any exception for this solution which works in normal conditions. Please see the following code.
CreationTime:=0 only identifies the first browser in a desktop instead of the top browser except that there is only one browser in a desktop.
I do it in another similar way. First calculate the total no of the browsers, then the top browser is the CreationTime:=total-1. I don't know whether there is any exception for this solution which works in normal conditions. Please see the following code.
Code:
Set oDesc = Description.Create()
oDesc("micclass").Value = "Link"
Set Links = Browser("title:=Google").Page("title:=Google").ChildObjects(oDesc)
Links(3).click
Dim oDescB
Set oDescB=Description.Create()
oDescB("micclass").Value="Browser"
Set oDescB = DeskTop.ChildObjects(oDescB)
Browser("CreationTime:=" & oDescB.count-1).back
Set oDescB=nothing
Set Links=nothing