fbpx

Problem in Using Function

Problem in Using Function

Home Forums Ask Expert Problem in Using Function

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #31336
    abhinav kumar
    Participant

      Hi,
      We are able to Click on SIGNIN object when directly using it without any function. But are not able to do anything after
      using function.
      ========================================================================================================
      ZAP File without using function:

      Launch “chrome”, “http://www.jio.com/”
      Application(“Jio”).View(“HomePage”).Object(“Jio”).Exist
      Application(“Jio”).View(“HomePage”).Object(“SIGNIN”).Click

      ========================================================================================================

      ZAP File with function:

      Launch “chrome”, “http://www.jio.com/”
      set obj1=Application(“Jio”).View(“HomePage”).Object(“Jio”)
      set obj2=Application(“Jio”).View(“HomePage”).Object(“SIGNIN”)

      function CheckAndClick(obj1,obj2)
      If obj1.Exist then
      obj2.Click
      End If
      end function
      ========================================================================================================
      Can you please check and let us know how to set functions correctly.

      #31337
      Kirill Bulatnikov
      Participant

        Hello, thanks for using ZAPTEST

        Your function looks OK but I cannot see call for a function. Did you place entire code to the message?
        In this case you simply not inserted it to the code?

        Thanks,
        ZAPTEST Team

        #31339
        abhinav kumar
        Participant

          Hi,

          Can you please modify the code and post it, showing how to call the function in Zaptest.

          Thanks

        Viewing 3 posts - 1 through 3 (of 3 total)
        • You must be logged in to reply to this topic.

        Virtual Expert

        ZAPTEST

        ZAPTEST Logo