VBA Connecting to Closed Workbook

craig80

Board Regular
Joined
May 18, 2010
Messages
51
Hi All,

I have a Data Workbook holding all data for my reports, I would like Query my this closed "Data Cube" (which is table format). But rather than build a connection through the DATA tab, I would like to use VBA?

(reasons for this is i am querying a data set which is on a intranet document storage, and cannot network this as a drive)

i.e. //internal/176/222/225/Reports/Data_Cube.xlbs

I need to get to a stage somewhere like this. ( can do the open, close, paste additional formula, its the middle bit)

VB

  • Open connection (As above)
  • refresh data connection
  • filter specific criteria out
  • refresh all pivot and forumlas on destination
  • close connection
  • save AS destination file twice
  • end
Thanks again to all those who have helped over the last year.

Craig
 

Excel Facts

Wildcard in VLOOKUP
Use =VLOOKUP("Apple*" to find apple, Apple, or applesauce

Forum statistics

Threads
1,215,635
Messages
6,125,942
Members
449,275
Latest member
jacob_mcbride

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