Posts: 10
Threads: 3
Joined: Sep 2010
Reputation:
0
11-03-2010, 02:45 PM
(This post was last modified: 11-03-2010, 03:02 PM by sasi1982.)
Hi,
I have a simple code where it creates excel object and add data to it. But i am getting the below run time error when i execute it. Can some please check and let me know solution.
run time error : ActiveX component can't create object: 'Excel.Application'
Thanks in advance.
Posts: 99
Threads: 0
Joined: Oct 2010
Reputation:
0
11-03-2010, 03:13 PM
Is statement like:
CreateObject("Excel.Application")
Posts: 10
Threads: 3
Joined: Sep 2010
Reputation:
0
11-03-2010, 03:29 PM
(This post was last modified: 11-03-2010, 03:36 PM by sasi1982.)
Yes kavitha. With that statement only i am getting the runtime error.
Kavitha, if i run the piece of code individually from QTP, it is working fine.
But, if add the funtion definition to the .vbs file and then call it from QTP, it is not working. .vbs is associated to the script. Can you please reply back immediately if you have solution.
Thanks ..
Posts: 10
Threads: 3
Joined: Sep 2010
Reputation:
0
11-03-2010, 04:28 PM
Hi saini,
i have checked it. it is fine.
Posts: 99
Threads: 0
Joined: Oct 2010
Reputation:
0
11-03-2010, 05:47 PM
Hi sasi
I tried your code it self.It is working fine for bothe the cases mentioned below:
1. When i run the script from QTP UI.
2. when i run the script in the invisible mode (after replacing the parameters with data).