Reputation: 203
I have a keyword driven framework. Keywords are all in VBscript plus descriptive programming. I created a script in excel which worked just fine after I ran it multiple times. Now it does not work. UFT is not clicking the right element, not entering in the edit field, etc. I had about 65 steps on that script. Now, this works on dev portal but not on the test portal. It worked on test portal over 50 times last week.
To debug, I simply first used the record and playback features and noticed that it does not work too.
I have a main menu in dot net page. Main menu has 5 links. I simply recorded the register link which is 3rd link and I see this code generated:
Browser("Portal").Page("Portal").Link("Register").Click
I went to OR and I saw register object was added just fine. Text = Register. From OR, when I clicked the highlight in app button, it did not highlight the register link. Instead, it highlighted the partially 2nd link which is "Fund".
When I run the script, it clicks the 2nd link Fund.
Why does it click on Fund link? Why does it highlight the Fund link partially?
I am talking about the test portal. If I do the exact same thing in the dev portal, I do not have the same issue. What could go wrong in test portal? Do you think application is blocking UFT from automating in their end or perhaps bad source code in the application?
Update 1
During recording, Clicked on register link, this code generated:
Browser("Browser").Page("Page").Link("Register").Click
Clicked on contact link, this code generated:
Browser("Browser").Page("Page_2").Link("Contact").Click
During run, first line clicks on fund instead of register. Second line clicks on register instead of contact.
Register link in OR Shows everything just fine. Contact link in OR shows contact info just fine.
When I hover over on register link, it recognizes contact link instead of register.
When I hover over on fund link, it recognizes register instead of fund.
Summary: During recording it recognizes correct link. During running it click on the previous link. This is a pattern I see so far.
Upvotes: 4
Views: 1911
Reputation: 203
Browser was set to 125% zoom. I reset to 100% and it worked out just fine. I am not sure why UFT confused during running because of zooming. UFT was able to find it just fine during recording but it clicks another element during running. I am glad at least it is fixed. Thanks.
Upvotes: 2