Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Executing RunAction along with Function Call
#1
Action 1:
Code:
Dim a, b, c a = 10 b = 20 c = 30 RunAction "Action2", 0, "Login_To_AUT " & """ & a & """, """ & b & """, """ & c & """

Action 2:

Code:
func = Parameter("Function") spc_func = InStr(1,func ," ") environment.Value("FnName") = Mid(func ,1,spc_func -1) Execute func Function Login_To_AUT(ByVal a, ByVal b, ByVal c) Print a Print b Print c End Function


Whenthe test was executed it stops at Action 1 of 'RunAction' Statement and displayed the below error.

You specified more parameters in your RunAction statement than the number of parameters defined for the action.

Could you please someone help to find what is the problem with the RunAction statement.
Reply
#2
try replacing your RunAction Statement -
Code:
RunAction "Action2", 0, "Login_To_AUT " & a & "," & b & ", " & c

Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  error when executing an UFT automation script alexalloza 0 2,269 10-30-2018, 06:17 PM
Last Post: alexalloza
  Executing via create "RES"xx folder? nishitd 0 2,000 03-07-2018, 01:09 AM
Last Post: nishitd
  QTP-Re-executing script after completion of all iterations JwalantBhatt0602 1 3,571 03-24-2016, 12:37 AM
Last Post: JwalantBhatt0602
  Calling a function in a Test Script from a function library anupam4j 3 7,552 06-26-2015, 12:31 AM
Last Post: babu123
  Not able to call the function kathirvelnagaraj 1 3,441 01-06-2015, 07:24 PM
Last Post: kathirvelnagaraj

Forum Jump:


Users browsing this thread: 1 Guest(s)