jon_yates
11 years agoOccasional Contributor
Why does this error?
Hello all.
Within a webpage I'm forcing some validation and checking for its presence:
var text = page["NativeWebObject"]["Find"]("contentText", "The Name already exists*", "span");
if(text["Enabled"])
{
Aliases["browser"]["page1921680200"]["panelBody"]["section"]["Panel"](0)["Panel"](3)["Panel"](1)["Click"](20,20);
}
else
{
Aliases["browser"]["page1921680200"]["panelBody"]["section"]["frame"]["panelContent"]["panelWidgetContext"]["panel2"]["panel"]["Click"](26, 30);
}
If this appears, I want to click a different button to that if there's no validation.
Everythig works except for the bold text (i,.e when there is no validation errors).
I used the object spy to identify the control but when it runs it errors with the below, can anyone please help why?
Within a webpage I'm forcing some validation and checking for its presence:
var text = page["NativeWebObject"]["Find"]("contentText", "The Name already exists*", "span");
if(text["Enabled"])
{
Aliases["browser"]["page1921680200"]["panelBody"]["section"]["Panel"](0)["Panel"](3)["Panel"](1)["Click"](20,20);
}
else
{
Aliases["browser"]["page1921680200"]["panelBody"]["section"]["frame"]["panelContent"]["panelWidgetContext"]["panel2"]["panel"]["Click"](26, 30);
}
If this appears, I want to click a different button to that if there's no validation.
Everythig works except for the bold text (i,.e when there is no validation errors).
I used the object spy to identify the control but when it runs it errors with the below, can anyone please help why?
You are trying to call the "panel" method or property of the following name mapping object:
Name mapping item: | section |
The test engine is unable to call this method (or property), because the object has a child object whose name coincides with the method's (or property's) name.
To call this method (property), you need to first obtain a reference to the underlying test object with the GetUnderlyingObject() method.