title: Accessing elements located by custom locator strategy with Javascript
body: <p>I have following issue:</p>
  
  <ul>
  <li>I have a checkbox which is hidden and there is another layer used to make it nice and shiny</li>
  <li>I can easily change its value by accessing its ID however I also need to access this element using my custom locator which uses xpath (that has to stay variable)</li>
  </ul>
  
  <p>So, here's my script:</p>
  
  <pre><code>Custom Select Checkbox    id=my_checkbox        #that works fine
  Custom Select Checkbox    customLocatorStrat    #that doesn't work at all
  
  *** Keywords ***
  Custom Select Checkbox
      [Arguments]    ${locator}    ${timeout}=${global_timeout}
      Execute Javascript    document.getElementById("${resultLocator}").checked = true;
      OR
      ${el}.checked = true;     #need to get the ${el} variable if the ${locator is not an id}
  
  
  My Custom Locator
      [Arguments]    ${criteria}    ${tag}    ${constraints}
      ...     #assembling xpath
      ${el}=    Get Webelements    xpath=${path}
      [Return]    ${el}
  </code></pre>
  
  <p>There is no issue with the locator strategy - it workes fine. I only need to use it/force it in my Custom Select Checkbox keyword. I need to get the ${el} variable and considering there's more than one Custom Locator keyword calling it directly will not work for me. Any idea how to do this please? Many thanks in advance.</p>