Forum Discussion

Tarzan1990's avatar
Tarzan1990
Occasional Contributor
4 years ago

Facing issue with COM calling keyword with parameter

Hi there,

 

I'm facing issue calling keyword with parameters via COM services 

If anyone can help quickly would be of great help

 

IntegrationObj.RunProjectTestItem(ProjectNameProjectTestItemName)

has only provision to pass keyword name, how to pass parameter ? is there any better alternative ?

 

Thanks

https://support.smartbear.com/testcomplete/docs/reference/project-objects/automation/integration/runprojecttestitem.html

  • AlexKaras's avatar
    AlexKaras
    Champion Level 3

    Hi,

     

    I would ask Support via the https://support.smartbear.com/testcomplete/message/ form.

    And I would appreciate it if you update this thread with their reply.

     

    Personally I have no better idea at the moment than try the GetObjectByName method (https://support.smartbear.com/testcomplete/docs/reference/project-objects/automation/integration/getobjectbyname.html) to get the reference to the keyword test object, set its parameters and then run this keyword test. But this is just a quick idea that I did not verify.

     

    • Tarzan1990's avatar
      Tarzan1990
      Occasional Contributor

      Hi  AlexKaras

       

      I'm not talking about the project variables. I wanted a solution for the keyword test item's parameter

       

      Thanks

      • AlexKaras's avatar
        AlexKaras
        Champion Level 3

        Hi,

         

        I'm not talking about the project variables.

        Obviously. But the idea was to obtain a reference to the Keyword Tests collection, then obtain a reference to the required keyword test, then obtain a reference to its parameters, set parameter's value and run this keyword test.

        As I said, this is just a rough idea based on quick look through the documentation without any real code examples.