RefreshMappingInfo() not working
SOLVED- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
RefreshMappingInfo() not working
My application is written in delphi.
when i run below code gets error "Python runtime error.
RuntimeError: 0x847ceed2" in Log.Message(childtab.Text) line...
by debugging found that RefreshMappingInfo() did not working
the code is below..
def closeAll(self): tabCount = Aliases.App.Browser.MDIClient.ChildCount for i in range (0,tabCount): Aliases.App.Browser.MDIClient.RefreshMappingInfo() Delay(5000,"Waiting everything to be refreshed...................") childtab = Aliases.App.Browser.MDIClient.Child(0) Log.Message(childtab.Text) childtab.close()
while debugging , when go to object browser ..could see deleted tab is there even though RefreshMappingInfo() runs.
So child(0) still refers to closed tab
when RMB and manually refreshed mapping infor, script runs correctly.
always first tab is closed correctly problem starts subsequent tabs .
any ideas..?
Solved! Go to Solution.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This is likely a timeing issue. I would suggest doing something along the lines of WaitAliasChild to wait for the tab to not exist.
Thanks,
Carson
Click the Accept as Solution button if my answer has helped
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
No use Waited for around a one and half minute......
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @NisHera . I found your support ticket for this issue. I am glad to know you've solved it!
Let me post the solution here for other community members to see:
Basically, the “Refresh()” method should be used before “RefreshMappingInfo” and it will update the child objects.
Great job!
Sonya Mihaljova
Community and Education Specialist
