Hyperlink vs Custom

Jan 8, 2014 at 4:10 PM
Hello All,

We ran into an interesting scenario involving a hyperlink <a> and I wanted to relay the information in case someone else has this problem. There is a link on one of our pages:

<a tabIndex="-1" class="chzn-single">

We wrote a line of CUITe code to interact with it however the automation came back and said that the link could not be found.

Here is the line:
public CUITe_HtmlHyperlink linkLogOutLink { get { return Get<CUITe_HtmlHyperlink>("class=chzn-single"); }}

When we looked into this more we realized that the automation was seeing the html above as an CUITe_HtmlCustom type and not CUITe_HtmlHyperlink.

In order to get the automation to recognize it as a Hyperlink we needed to add an href attribute to the tag like this:

<a href="javascript:void(0)” tabIndex="-1" class="chzn-single">

Once we added the tag then the automation picked this element up as a hyperlink.