Having issues running QC test cases using HP OTA client i.e. TDAPIOLELib from asp.net error is access denied error when triggering TSScheduler

StackOverflow https://stackoverflow.com/questions/19335777

Frage

I am facing issues triggering test cases in QC by using the TDAPIOLELib library. When i debug the application using Visual studio 2010, the QC scheduler starts running and then the test case is also run in remote machine, but after deploying in IIS i am getting error as access denied on the line where startexecution is triggered.

    TSScheduler scheduler = testset.StartExecution(""); /* Getting access denied error in this line  */
    scheduler.TdHostName = "RemoteMachineNameHavingQTP";
    scheduler.Run();

Got this error by using try-catch block when accessing the web application hosted in IIS. But no issues when debugging the application in visual studio. While debugging i am able to notice is that, when an object for TSScheduler is created in the code, the scheduler is getting triggered in my machine and able to see it in my task bar near date. But it is weird that it is causing error when accessed from outside. Is it related to IIS or can anyone suggest on how to resolve this issue?

War es hilfreich?

Lösung

Finally found it, went to run->eventvwr. Then checked for errors. There was an error with COM exception. Then gave necessary access to the COM object following the instructions given for the error code by microsoft.

Basically the user machinename\asp.net did not have access to the scheduler exe which is present in the machine. While debugging it worked since i was the administrator, after hosting it did not work after giving necessary access it worked.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top