Using Quality Center Field value for SOAtest script execution

LegacyForumLegacyForum Posts: 1,669 ✭✭
edited December 2016 in SOAtest
SOATest 5.5.3 and QC API

I am using HP Quality Center10.0 for executing my Parasoft SOATest Script using the Javascript API of SOATest-QC.

I wanted to use the value of a field in Quality Center Test Plan Details tab.


I have added a field in Quality Center 10.0 Test Plan -->Details Tab.

Field Name is SOAEnvironment(Drop Down List) having value like CERT,STAGE,PROD.

I wanted user to Select one of the value in the above field.

Then use the Environment value (e.g CERT) with in the QC script like :

if (additionalArgs != "") {
args += " -environment " + additionalArgs;
//additionalArgs - stores the value of field SOAEnvironment.


Finally Create the CLI command like :

st.exe -cmd -runtest testSuite -reportHTML xmlReport -environment additionalArgs

So, could you please let me know how can I access this required from the Javascript within QC?
Any Pointer on the above appreciated.


  • LegacyForumLegacyForum Posts: 1,669 ✭✭
    I believe you can access the field's value in your JavaScript by calling something like CurrentTest.Test.Field("SOME_FIELD_ID"). You would need to know the ID of your custom Test field. If you click Tools->Customize...->Project Entities then expand "Test->User Fields" then click the name of your custom Test field, you should see "Field Name". This may have some cryptic value such as "TS_USER_123" or something. This is the ID of your custom field.

    You can find more details about QC's API from "Help->Documentation Library->HP Quality Center Open Test Architecture API Reference". The Test object and its Field property are described in this OTA API reference.
Sign In or Register to comment.