cancel
Showing results for 
Search instead for 
Did you mean: 

Object required: 'TestedApps' error

SOLVED
Highlighted
New Contributor

Object required: 'TestedApps' error

Hello,

I am trying to run the script which is using the extension created by me. But I get an error: Object required: 'TestedApps'.  Here is the function which I am trying to run using WMI object. Can anyone help to handle this error?

 

This is function in my extension

Sub FillLoginForm()
    TestedApps.Items("ApplicationName").Run()
End Sub

 

This is my function call, by using extension

Sub Test()
     WMI.FillLoginForm
End Sub

 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Hero

Re: Object required: 'TestedApps' error

Hi,

 

script which is using the extension

If you are talking about Script Extension, then TestedApps object is not available to the Script Extension (https://support.smartbear.com/testcomplete/docs/working-with/extending/script/objects-reference/inde...).
But it is interesting that TestedApps object can be passed as a parameter and the code works as expected...

 

Regards,
  /Alex [Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
================================

View solution in original post

5 REPLIES 5
Highlighted
Community Hero

Re: Object required: 'TestedApps' error

TestedApps doesn't want a project name as a parameter.  It wants an application name.

https://support.smartbear.com/testcomplete/docs/reference/project-objects/items/tested-apps/testedap...

Highlighted
New Contributor

Re: Object required: 'TestedApps' error

Yes, but in my case the project name matches the application name. 
When I change the code as follows it starts working properly

This is function in my extension

Sub FillLoginForm("App")
    App.Items("ApplicationName").Run()
End Sub

 

This is my function call, by using extension

Sub Test()
     WMI.FillLoginForm TestedApps
End Sub

Highlighted
Community Hero

Re: Object required: 'TestedApps' error

Is there still a problem?  Looks like you fixed it by updating the parameter.

Highlighted
Community Hero

Re: Object required: 'TestedApps' error

Hi,

 

script which is using the extension

If you are talking about Script Extension, then TestedApps object is not available to the Script Extension (https://support.smartbear.com/testcomplete/docs/working-with/extending/script/objects-reference/inde...).
But it is interesting that TestedApps object can be passed as a parameter and the code works as expected...

 

Regards,
  /Alex [Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
================================

View solution in original post

Highlighted
Community Manager

Re: Object required: 'TestedApps' error

Thank you for your replies Alex and Marsha.

 

@Olya Please let the Community know if there's something else we can help you with. Or, does the fixed code you posted serve as a workaround for you?


Sonya Mihaljova
Community and Education Specialist

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️
New Here?
Join us and watch the welcome video:
Announcements
Top Kudoed Authors