Detecting Workbook created by another Application

Koltack

New Member
Joined
May 2, 2018
Messages
2
Hello Everyone,

I recently started working with Excel, and VBA for that matter.

I currently have an application that exports its data to a new excel sheet, And I would like to be able to click a button, Copy the data from the sheet I need, and paste it into my current workbook. I figured out how to take data from another workbook opened or created with excel, but am not able to see the workbook created by the export in my main workbook.

Is there a method to detect workbooks created or opened by another application?
 

Excel Facts

Waterfall charts in Excel?
Office 365 customers have access to Waterfall charts since late 2016. They were added to Excel 2019.
Hi,

mayby: in the attributes and the xml there are many information including the xl-version.

First use the win-explorer to check the file-attributes. If there is a valuable field, you can use the "namespace" to check this with vba.

Second: rename by hand the file to ".zip", open it in the win-explorer (NOT extract) and have a look to app.xml, core.xlm and workbook.xml. If there is meaningful information for you, it can be checked also with vba "namespace". If necessary use a search engine with "namespace unzip" and check the examples of a dutch "guru".

A feedback is appreciated.

regards
 
Upvote 0
Hi,

mayby: in the attributes and the xml there are many information including the xl-version.

First use the win-explorer to check the file-attributes. If there is a valuable field, you can use the "namespace" to check this with vba.

Second: rename by hand the file to ".zip", open it in the win-explorer (NOT extract) and have a look to app.xml, core.xlm and workbook.xml. If there is meaningful information for you, it can be checked also with vba "namespace". If necessary use a search engine with "namespace unzip" and check the examples of a dutch "guru".

A feedback is appreciated.

regards

At the moment the application creates a new excel sheet, but it is not saved anywhere, so I'm not sure of a way to see the file in win-explorer without saving it. If I save the document and reopen it am able to find the workbook perfectly, although id like to avoid this step, as My main purpose of this process is to perform a copy paste and this would take longer.

I would also like to mention that I am currently grabbing the last open workbook by using "Workbooks(Workbooks.Count)", and the count is not updated when the application creates a new workbook but is when existing one is opened from file explorer or created through excel. I am not able to find a way to add the application created excel to my main instances list
 
Upvote 0
Hi,

ok, now it beocomes a bit clearer: it seem the other application is creating a new instance of Excel. You can check this with Win-API's or with Word VBA and Tasks.

regards
 
Upvote 0
At the moment the application creates a new excel sheet, but it is not saved anywhere, so I'm not sure of a way to see the file in win-explorer without saving it. If I save the document and reopen it am able to find the workbook perfectly, although id like to avoid this step, as My main purpose of this process is to perform a copy paste and this would take longer.

I would also like to mention that I am currently grabbing the last open workbook by using "Workbooks(Workbooks.Count)", and the count is not updated when the application creates a new workbook but is when existing one is opened from file explorer or created through excel. I am not able to find a way to add the application created excel to my main instances list

Are the other application and the workbook in it both created by your vba code ?
 
Last edited:
Upvote 0

Forum statistics

Threads
1,223,888
Messages
6,175,213
Members
452,618
Latest member
Tam84

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top