![]() |
WaitProperty does not refresh the object (WebNumber) - 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: UFT / QTP Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners) +--- Thread: WaitProperty does not refresh the object (WebNumber) (/Thread-WaitProperty-does-not-refresh-the-object-WebNumber) |
WaitProperty does not refresh the object (WebNumber) - cantorre - 05-10-2017 Hi, In my application I have a Search table (which is a WebElement), which has a Paging section "Page X of Y". The "X" is a WebNumber. Since I am having synchronization issues, I figured, that I am going to inspect that "X" whenever I need to flip to the next page. So here is what I tried Code: If (Browser("WebBrowser").Page("MainPage").WebElement("MyTable").WebNumber("PagingObject").WaitProperty("value", 2, 10000)) Then But that does not work, even though next page is visible, that "value" in that WebNumber is still 1. What is more funny, after those 10s when I try Code: Browser("WebBrowser").Page("MainPage").WebElement("MyTable").WebNumber("PagingObject").GetROProperty("value") it is now 2... So it seems that WaitProperty did not refresh. I have changed that WebNumber into a WebEdit in my OR, but that didn't solve it. I ended up doing this Code: Set pagingObject = Browser("WebBrowser").Page("MainPage").WebElement("MyTable").WebNumber("PagingObject") The key was that RefreshObject. But I really don't like it. Can anyone help me? Why is it not refreshing? Regards |