Forum Discussion

Logiv's avatar
Logiv
Contributor
4 years ago
Solved

Setting project variable using InputBox

Hello, Previously I was able to create a little sript to get the user to input a path at the start of the test, and then grab a EXE version from that path. My goal was to save the TestComplete Pr...
  • BenoitB's avatar
    BenoitB
    4 years ago

    "ProjectSuite.Variables.VariableByName["EXEPath"] =
    BuiltIn.InputBox("Find EXE path", "Enter EXE Program Files path:", "")

    But the second line shows error "Unexcepted TKN_NewLine""

     

    Is it intented to go new ligne after the = ?

     I don't use PY but according to the error msg i think that you must remove this carriage return and write all on same line :

    ProjectSuite.Variables.VariableByName["EXEPath"] = BuiltIn.InputBox("Find EXE path", "Enter EXE Program Files path:", "")