Forum Discussion

lodecesa's avatar
lodecesa
Contributor
2 years ago

Reference to an HTML object having a string with his mapped name

Hi to all, I have the mapped name of an HTML object in a string and I want find its reference with a method like this:   var elementReference = Aliases.browser.page.form.byName(mappedName);   Tha...
  • AlexKaras's avatar
    2 years ago

    Hi,

     

    Assuming that you have:

    var aStr = "Aliases.browser.page.form.mappedName";

    Are you looking for this:

    var anObj = eval(aStr);

    ?