URGENT: ActiveX component can't create object - Printable Version +- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums) +-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP) +--- Forum: UFT / QTP Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners) +--- Thread: URGENT: ActiveX component can't create object (/Thread-URGENT-ActiveX-component-can-t-create-object) |
URGENT: ActiveX component can't create object - citibank_ani - 08-03-2010 I created a test in QTProff and then tried to run the test from the command prompt through this script. I fired the commands from C prompt: 1) cscript //nologo C:\Daily_Status_Checkout\Daily_Checkout.vbs Where C:\Daily_Status_Checkout is my QTP script test location and Daily_Checkout.vbs is the script mentioned below. Gave below mentioned error - C:\Daily_Status_Checkout\Daily_Checkout.vbs(5, 1) Microsoft VBScript runtime error: ActiveX component can't create object: 'QuickTest.Application' 2) wscript C:\Daily_Status_Checkout\Daily_Checkout.vbs Gave the attached error in a picture file. C:\Daily_Status_Checkout\Daily_Checkout.vbs file: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Code: Dim qtApp 'As QuickTest.Application ' Declare the Application object variable qtApp.Open "C:\Daily_Status_Checkout", True ' Open the test in read-only mode ' set run settings for the test Code: Set qtTest = qtApp.Test Please help me in running this automatically. I have tried adding some snippets as well to the script as shown below to kill any running session of QTProff. Code: Dim objWMIService, objProcess, colProcess which also gave me the same error, asserting the fact that this was not the issue. So someone please guide me. RE: URGENT: ActiveX component can't create object - sasmitakumari - 08-03-2010 Were you able to run same script, previously? If so, then it could be timing issue, QTP might be taking more time to open than expected. Restart you machine, and try it again. RE: URGENT: ActiveX component can't create object - citibank_ani - 08-03-2010 I wasn't able to run the script at any time. I am getting this error from the time I tried to do this. Also like before running every time I have checked whether QTP is running or not, and ran the script only when there are no instances of QTP running in back/foreground. One information I would like to provide is that I don't have admin rights on the machine in which I am running this. RE: URGENT: ActiveX component can't create object - VarunKaushik - 09-09-2014 which QTP version you are running. If QTP 10.5 & below then follow these steps open cmd as adminstrator "C:\Program Files\HP\QuickTest Professional\bin\QTAutomationAgent.exe.exe" /regserver if 11.53 & above "C:\Program Files\HP\QuickTest Professional\bin\QtpAutomationAgent.exe.exe" /regserver |