How to store Excel sheet names in different buffers

Scenario: User wants to store Excel worksheet names in different buffers.

Answer:

This can be achieved by scanning one of the Excel tab by using UIA engine. 

1. Scan Excel tab by using UIA Engine (Scan Application -> Desktop scan -> Right click on the Excel file -> Select UIA Engine). Here, I have scanned all 6 tabs as per our example just to show all the tabs. All 6 sheets are uniquely identified by its Name property. 

Remove other 5 sheet tabs as it was just shown for demonstration.

Change Technical Property Name to Sheet Tab* as per below screenshot. By doing so, this control will not be shown as uniquely identified.

As control is not identified uniquely, Tosca xscan will show total number of similar controls when “Identify by Index” is selected. Save the module.

2. Create a test case and use TBox Start Program module to open Excel file.

3. As soon as the tab gets visible, Get ResultCount of number of Tabs present in an Excel file by applying ResultCount property in scanned module.

SheetNo will store total number of tabs present in an Excel file, which are 6 in this case.

4. Store Sheetnames in 6 different buffers using “Name” property as shown in below example.

RESULT:

About The Author

4.5 2 votes
Article Rating
Subscribe
Notify of
guest
2 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Sirinath
Sirinath
4 months ago

This could very helpful for me thank you Next IT Career

Sai
Sai
4 months ago

I was facing in real-time SAP project scenario.

Thanks Next it career provided clear explanation.

Related Posts

2
0
Would love your thoughts, please comment.x
()
x