Micro Focus QTP (UFT) Forums
Not able to record Compose Mail WebElement from Gmail.com - Printable Version

+- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums)
+-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP)
+--- Forum: VB Scripting/Descriptive Programming (https://www.learnqtp.com/forums/Forum-VB-Scripting-Descriptive-Programming)
+--- Thread: Not able to record Compose Mail WebElement from Gmail.com (/Thread-Not-able-to-record-Compose-Mail-WebElement-from-Gmail-com)



Not able to record Compose Mail WebElement from Gmail.com - upadhyay40 - 11-23-2009

Hello All,

I want to record Compose Mail WebElement from Frame v1, but i tried a lot but i am not able to record Compose mail, even i write some descriptive programming but it shows Frame v1 is not found, i save Frame v1 in object repository, so can anybody please help me out, hoping for cooperation

Thanks
Mahesh
Hello All,

I want to record Compose Mail WebElement from Frame v1, but i tried a lot but i am not able to record Compose mail, even i write some descriptive programming but it shows Frame v1 is not found, i save Frame v1 in object repository, so can anybody please help me out, hoping for cooperation

Thanks
Mahesh


RE: Not able to record Compose Mail WebElement from Gmail.com - upadhyay40 - 11-23-2009

Hello All,

I achieve the same one,


Code:
Dim NumberOfEdits, webElementToSearch
webElementToSearch="<B>Compose Mail</B>"
Set oDesc = Description.Create
oDesc("html tag").Value = "B"
oDesc("micclass").Value = "WebElement"
oDesc("innertext").Value = "Compose Mail"
oDesc("outertext").Value = "Compose Mail"
oDesc("innerhtml").Value = "Compose Mail"
oDesc("outerhtml").Value = "<B>Compose Mail</B>"

Set EditCollection = Browser("title:=Gmail").Page("title:=Gmail.*").ChildObjects(oDesc)

NumberOfEdits = EditCollection.Count


For i = 0 To NumberOfEdits - 1
    If EditCollection(i).GetROProperty("outerhtml") = webElementToSearch Then
      EditCollection(i).Click
    End If

Next

Thanks
Mahesh