title: run keyword if error invalid syntax (<string>, line 1)
body: <p>I am new to this run keyword if method.</p>
  <p>I wanted to enter different number based on specific page.</p>
  <p>e.g. if page1 element is detected then input number 1, if page2 then input number 2.</p>
  <pre><code>*** Settings ***
  Library    Selenium2Library
  Library    Collections
  Resource   ../Resources/nine-res-work.robot
  
  *** Variables ***
  ${LOGIN-BUTTON-NUMBER-1}   ${ANDROID-WIDGET-TEXT-VIEW}\[@resource-id=&quot;com.test.abc.work.cac:id/btn_number&quot; and @text=&quot;1&quot;]
  ${LOGIN-BUTTON-NUMBER-2}   ${ANDROID-WIDGET-TEXT-VIEW}\[@resource-id=&quot;com.test.abc.work.cac:id/btn_number&quot; and @text=&quot;2&quot;]
  ${LOGIN-BUTTON-NUMBER-3}   ${ANDROID-WIDGET-TEXT-VIEW}\[@resource-id=&quot;com.test.abc.work.cac:id/btn_number&quot; and @text=&quot;3&quot;]
  
  ${LOGIN-PAGE-HEARDER-page1}         ${ANDROID-WIDGET-TEXT-VIEW}\[@resource-id=&quot;com.test.abc.work.cac:id/headerText&quot; and @text=&quot;Enter your PIN.&quot;]
  ${LOGIN-PAGE-HEARDER-page2}               ${ANDROID-WIDGET-TEXT-VIEW}\[@resource-id=&quot;com.test.abc.work.cac:id/headerText&quot; and @text=&quot;Enter your passcode.&quot;]
  
  
  *** Keywords ***
  Smart Card Login
      Run Keyword If  ${LOGIN-PAGE-HEARDER-page1} == 'PASS'   Tap     ${LOGIN-BUTTON-NUMBER-1}
      Run Keyword If  ${LOGIN-PAGE-HEARDER-page2} == 'PASS'   Tap     ${LOGIN-BUTTON-NUMBER-2}
  
  *** Test Cases ***
  Test 1
      Launch Application
      Smart Card Login
  </code></pre>
  <p>error</p>
  <pre><code>Test 1  | FAIL |
  Evaluating expression '//android.widget.TextView[@resource-id=&quot;com.test.abc.work.cac:id/headerText&quot; and @text=&quot;Enter your PIN.&quot;] == 'PASS'' failed: SyntaxError: invalid syntax (&lt;string&gt;, line 1)
  </code></pre>
  <p><strong>I have tried another way, this time no error but the tap action isn't execute.</strong></p>
  <pre><code>*** Variables ***
  ${LOGIN-BUTTON-NUMBER-1}   ${ANDROID-WIDGET-TEXT-VIEW}\[@resource-id=&quot;com.test.abc.work.cac:id/btn_number&quot; and @text=&quot;1&quot;]
  ${LOGIN-BUTTON-NUMBER-2}   ${ANDROID-WIDGET-TEXT-VIEW}\[@resource-id=&quot;com.test.abc.work.cac:id/btn_number&quot; and @text=&quot;2&quot;]
  ${LOGIN-BUTTON-NUMBER-3}   ${ANDROID-WIDGET-TEXT-VIEW}\[@resource-id=&quot;com.test.abc.work.cac:id/btn_number&quot; and @text=&quot;3&quot;]
  
  ${LOGIN-PAGE-HEARDER-page1}         ${ANDROID-WIDGET-TEXT-VIEW}\[@text=&quot;Enter your PIN.&quot;]
  ${LOGIN-PAGE-HEARDER-page2}               ${ANDROID-WIDGET-TEXT-VIEW}\[@text=&quot;Enter your passcode.&quot;]
  
  
  *** Keywords ***
  Input App Passcode
      Tap     ${LOGIN-BUTTON-NUMBER-2}
  
  
  *** Test Cases ***
  Launch App
      Open Nine Folders Application
      Sleep   5s
  
  Input Password
      ${Page1} =    Page Should Contain Element    ${LOGIN-PAGE-HEARDER-page1}
      Run Keyword If      '${Page1}' == 'PASS'      Input App Passcode
  </code></pre>