This site requires JavaScript to be enabled

Tosca Version
IncidentLookup using list
How can we help?

Solution Suggestions

Please enter your question to get suggestions.
Boolean Operators
OR or vertical bar symbol (|)
Finds a match if either the terms exist in a document (a union using sets).
Finds a match if both terms exist in a document (an intersection of sets).
NOT, minus (-), or exclamation point (!)
Excludes documents that contain the term after NOT (a difference of sets).
Asterisk (*)
The asterisk symbol performs a multi character wildcard search.
Percent sign (%)
The percent sign performs a single character wildcard search.
Quotation marks (")
Use quotation marks to search for an exact phrase with multiple terms.
For examples and more information look at our Knowledge Base: Advanced Search On The Support Portal

Test Automation

Is it possible to automate the Excel macro application,Since while i use Wizard scan i getting "Windows call stack error" after scanning.

Kindly share any example with respect macro applcation automated


1 0

Alex Brandenberger

Created: 2016-09-12 17:30:39 , Updates: 1, Last Update: 2016-09-12 17:37:08

Hello Sreenivash


You can use the Excel Objects in your VBScript / C# Keywords for your Tosca Modules.

-> Set xlApp = CreateObject("Excel.Application")    for VBScript

-> Excel.Application xlApp = new         for C#


... or you can download the Excel Engine here:



2 0

Rahul S S

Created: 2016-09-21 14:35:25

Hi Sreenivash,

Short answer to your question would be: Yes, we can automated Excel macro based applications using TOSCA.

For this automation you need to use a combination of the TOSCA Excel Engine and TC Send Keys to effectively automate any functionality in your macro application.

The general idea: The generic Excel engine modules will help you interact with an Excel workbook and it offers various functionalities, inclusive but not limited to:

1. Defining which workbook/worksheet is active

2. Defining a range in the worksheet to work with the data that is present in it

3. Manipulating the data that is present in a particular range

The first link that Alex has specified in his solution given above can be used to download the generic excel modules.

Working with ActiveX controls (like buttons, etc): This is the tricky part. Sometimes it is a possibility that there are certain Form controls or ActiveX controls present in your excel macro application. These objects cannot be captured using TOSCA wizard as they are not recognizable out-of-box. Now you have only 2 options:

1. Customize the engine so that these controls are recognized

2. If the control is a button control, then you could use a workaround, without having to customize the engine. Read below for more details on this.

Button Controls: The idea is that every button control present in your macro application is associated with a macro. So when you click on the button, a particular macro is triggered and a certain action happens. In automation mode, you could directly run this macro, so that you would still be able to test the funtionality/action that happens when this button is clicked. Both these secanrios are equivalent in terms of the output.

For this you would have to use the "TC Send Key" module or the "TBox Send Keys" xmodule. By using these modules, you can send shortcut keys (in this case Alt + F8) to access the "View Macros" window in excel which lists all the available macros. Then use the same techinique to select a macro that is associated with your button and click on Run to execute the macro. In essence you would have automated the functionality of clicking on the button control, without actually having to click on it.

Hope this helps. Best of luck with your automation journey.

Best Regards,


Sindoori Peddi

2019-03-05 12:13:07

Hi Rahul,

I my case, the macro is locked with a password, so I think I can not use the alternative approach.

Could you please let me know how to customize the engine in order to get the button controls recognized?

Thanks in Advance



0 0

Ramesh T

Created: 2019-06-20 13:26:07

We  are also facing the same challenge of automating macro and its password protected as well. Please help us


Tosca is the perfect solution

Optimize - Manage - Automate

Download Trial