Highlighted
Absent Member.
Absent Member.
954 views

Inserted WebEdit value is not sticking in UFT during playback

My application has a dropdown, UFT is recognizing it as WebEdit. I am able to record dropdown but during playback inserted value is not sticking. Getting cleared as cursor moves out of that field.

Tried all these diff ways but none of them worked:

1. Browser("abc").Page("abc").WebEdit("d-0184").object.value = "Corporation"
2. Browser("abc").Page("abc").WebEdit("d-0184").Set "Corporation"
3. Set WshShell = CreateObject("WScript.Shell")
Browser("abc").Page("abc").WebEdit("d-0184").Click
WshShell.SendKeys("Corporation")
Set WshShell = Nothing
4. Setting.WebPackage("ReplayType") = 2
Browser("abc").Page("abc").WebEdit("d-0184").Set "Corporation"
Setting.WebPackage("ReplayType") = 1

None of above codes are throwing any error but during playback value is not sticking into the field. Getting cleared out after exiting that field.

Can someone suggest me any diff approach?

Thanks,
 SEGA

0 Likes
5 Replies
Highlighted
Absent Member.. Absent Member..
Absent Member..

Re: Inserted WebEdit value is not sticking in UFT during playback

What version of UFT are you using?

 

What version of what Browswer are you testing?

 

What is the technology of your web application?

 

What add-ins do you have loaded for UFT?

 

Have you tried the Type method for the WebEdit?

[If this post solves or helps solve your issue, mark the thread as solved and give KUDOS to the author for their assistance.]

(Opinions expressed in my postings are mine alone, and do not reflect the opinions of my employer.No warranties express or implied for any solution/suggestion posted.)
0 Likes
Highlighted
Absent Member.
Absent Member.

Re: Inserted WebEdit value is not sticking in UFT during playback

I am using UFT 12.02 version.

 

I am testing in IE 11.0.9600.17691

 

It is .Net application and i am using web add-in

 

UFT is not accepting Type method for WebEdit.

 

UFT don't have any issue in recognizing the application and elements on page. But entered value is not sticking on field.

 

After adding this shellscript, once it worked fine and immediately next time it failing to stick value into the dropdown. it is not consistent behavior.

 

Browser("Certificate Error: Navigation").Page("GAS - Georgia Tax Center_5").WebEdit("d-0184").object.value = "Corporation"

 Set WshShell = CreateObject("WScript.Shell")
 WshShell.AppActivate "Windows Internet Explorer"
 wait(1)
 WshShell.SendKeys "{TAB}"
 Set WshShell = nothing

 

 

Thanks,

Priya

 

 

0 Likes
Highlighted
Absent Member.. Absent Member..
Absent Member..

Re: Inserted WebEdit value is not sticking in UFT during playback

If it is a .NET application, why aren't you loading the .NET add-in?

 

If the object is a drop down list it should be getting recognized as a WebList, not a WebEdit. And the code for selecting a value from a WebList looks like this:

 

Browser("").Page("").WebList("").Select "<value from list>"

 

[If this post solves or helps solve your issue, mark the thread as solved and give KUDOS to the author for their assistance.]

(Opinions expressed in my postings are mine alone, and do not reflect the opinions of my employer.No warranties express or implied for any solution/suggestion posted.)
0 Likes
Highlighted
Absent Member.
Absent Member.

Re: Inserted WebEdit value is not sticking in UFT during playback

Hi ,

 

I tried with .Net add-in and this object is still recognized as WebEdit not as WebList.

 

I am attaching proprties of this object.

 

 

I am not sure how to resolve this issue?

 

Thanks,

Priya.

 

 

0 Likes
Highlighted
Honored Contributor.. Honored Contributor..
Honored Contributor..

Re: Inserted WebEdit value is not sticking in UFT during playback

Assuming the dropdown list displays when you click the 'WebEdit', perhaps you could then subsequently click the element in the list that you desire?

 

ie:

Set oDesc = Description.Create

oDesc("micclass").Value = "WebElement"

oDesc("innertext").Value = "Corporation"

Browser("abc").Page("abc").WebEdit("d-0184").Click

Wait 0, 100

Set oWeb = Browser("abc").Page("abc").ChildObjects(oDesc)

If oWeb.Count > 0 Then

     oWeb(0).Click

Else

     Reporter.ReportEvent micFail, "Target not found.", "Target.."

End If

Set oWeb = Nothing

Set oDesc = Nothing

 

Regards,

Ray

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.