Micro Focus QTP (UFT) Forums
Sometimes the QTP do not fill the WebEdit field. - 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: Sometimes the QTP do not fill the WebEdit field. (/Thread-Sometimes-the-QTP-do-not-fill-the-WebEdit-field)



Sometimes the QTP do not fill the WebEdit field. - QTP_Gaspar - 02-14-2011

Hi,

I have a Website, in C#.net, and I usually test it using the QTP tool. This works fine, but there are 2 WebEdit fields that sometimes simply do not get filled by QTP.
The QTP focus on the field, but do not obey the command to fill it.
Here is the the command block:

Code:
Browser("title:=Page.*").Page("title:=Page.*").WebEdit("html id:=txtDe").Click
Browser("title:=Page.*").Page("title:=Page.*").WebEdit("html id:=txtDe").Set X 'X is a variable
Browser("title:=Page.*").Page("title:=Page.*").WebEdit("html id:=txtDe").Click

I use the command "click", because there is a command that it's necessary to click on the field to auto-complete what I was typing.

Is there anybody able to help me with this problem ?

Sometimes the field gets filled, and sometimes not. It`s really weird.

Thank you very much.


RE: Sometimes the QTP do not fill the WebEdit field. - mufiani - 02-15-2011

Try in this way

Code:
Set fill = Description.Create
fill ("type").value = "text"
fill ("html id").value = "txtDe"
Browser("title:=Page.*").Page("title:=Page.*").WebEdit(fill).Set X



RE: Sometimes the QTP do not fill the WebEdit field. - QTP_Gaspar - 02-16-2011

Thank you very much, but it doesn't work either. =/


RE: Sometimes the QTP do not fill the WebEdit field. - jsknight1969 - 02-16-2011

I'm only guessing here, try using the name property instead. I'm assuming you did a view source on the page and verified the exact ID. My developers like to use .NET forms which can make some truly ugly html tags...especially if they use repeaters and grids.

Hope this helps.


RE: Sometimes the QTP do not fill the WebEdit field. - mufiani - 02-16-2011

Are you getting any error??? If so send me that error.
Which QTP version u r using??


RE: Sometimes the QTP do not fill the WebEdit field. - QTP_Gaspar - 02-22-2011

As I can see, it might be an error on my system development. The developers will change the KeyDown. I will wait for the change and test again.

Thank you all very much.