Results 1 to 3 of 3

Thread: Calling action on condition basis

  1. #1
    Junior Member
    Join Date
    Oct 2007
    Answers
    2

    Calling action on condition basis

    I have 2 actions in my test action A and action B (reusable action). and I am calling action B from action A on the condition basis.
    If Then
    RunAction "action A", oneIteration
    else
    fail
    End if.
    After running the script if the condition fails in the if clause still the action B is getting called which I dont want. Can anyone please help me out.


  2. #2
    Expert Member
    Join Date
    Oct 2007
    Answers
    375

    Re: Calling action on condition basis

    Hi Prafullan,

    Could you please send your code across as it is not a bit unclear about where Action B is being called.....

    Else as a firsthand attempt try the exit() function after the else clause statements. This should cause you to exit from the action and break the flow.

    Cheers


  3. #3
    Junior Member
    Join Date
    Oct 2007
    Answers
    9

    Re: Calling action on condition basis

    Hi,

    In your code, always if clause condition is successful, so its always calling actionB from actionA, you better modify your code like below,

    Dim flag
    flag =1
    If flag=1 Then
    RunAction "actionA", oneIteration
    else
    exit()
    End if

    Hope it may helpful.

    Regards,
    Vasanth


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
About us
Applying for a job can be a stressful and frustrating experience, especially for someone who has never done it before. Considering that you are competing for the position with a at least a dozen other applicants, it is imperative that you thoroughly prepare for the job interview, in order to stand a good chance of getting hired. That's where GeekInterview can help.
Interact