Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default Breaking the External Data Link

I create reports using an SQL to external data. The report then copies
particular data to division tabs and saves as a separate file. The trouble
is when we open the new spreadsheet there is a link to that External data
and if someone tries to refresh the data, they see my datasource and login.
How do I get rid of the Link to the external data source on the copied
pages?

TIA
Candyman


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,494
Default Breaking the External Data Link

would this work for you

sub remove()
Dim MyQT As QueryTable
Dim i As Long
Dim j As Long
Dim sheet As Worksheet

For Each sheet In Sheets
i = sheet.Index
For j = Worksheets(i).QueryTables.Count To 1 Step -1
Set MyQT = Worksheets(i).QueryTables(j)
MyQT.Delete
Next
Next
end sub

--


Gary


"Carl" wrote in message
news:iUUzf.9837$jR.9464@fed1read01...
I create reports using an SQL to external data. The report then copies
particular data to division tabs and saves as a separate file. The trouble
is when we open the new spreadsheet there is a link to that External data
and if someone tries to refresh the data, they see my datasource and login.
How do I get rid of the Link to the external data source on the copied
pages?

TIA
Candyman



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default Breaking the External Data Link

That was perfect! Thank you so much. I implemented on friday but could not
see the final tested results until today.
Carl

"Gary Keramidas" <GKeramidasATmsn.com wrote in message
...
would this work for you

sub remove()
Dim MyQT As QueryTable
Dim i As Long
Dim j As Long
Dim sheet As Worksheet

For Each sheet In Sheets
i = sheet.Index
For j = Worksheets(i).QueryTables.Count To 1 Step -1
Set MyQT = Worksheets(i).QueryTables(j)
MyQT.Delete
Next
Next
end sub

--


Gary


"Carl" wrote in message
news:iUUzf.9837$jR.9464@fed1read01...
I create reports using an SQL to external data. The report then copies
particular data to division tabs and saves as a separate file. The trouble
is when we open the new spreadsheet there is a link to that External data
and if someone tries to refresh the data, they see my datasource and
login.
How do I get rid of the Link to the external data source on the copied
pages?

TIA
Candyman





  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,494
Default Breaking the External Data Link

you're welcome, i think bob p or tom o gave me something similar a while back,
so thanks goes to them, too.

--


Gary


"Carl" wrote in message
news:U6jBf.11225$jR.6655@fed1read01...
That was perfect! Thank you so much. I implemented on friday but could not see
the final tested results until today.
Carl

"Gary Keramidas" <GKeramidasATmsn.com wrote in message
...
would this work for you

sub remove()
Dim MyQT As QueryTable
Dim i As Long
Dim j As Long
Dim sheet As Worksheet

For Each sheet In Sheets
i = sheet.Index
For j = Worksheets(i).QueryTables.Count To 1 Step -1
Set MyQT = Worksheets(i).QueryTables(j)
MyQT.Delete
Next
Next
end sub

--


Gary


"Carl" wrote in message
news:iUUzf.9837$jR.9464@fed1read01...
I create reports using an SQL to external data. The report then copies
particular data to division tabs and saves as a separate file. The trouble is
when we open the new spreadsheet there is a link to that External data and if
someone tries to refresh the data, they see my datasource and login.
How do I get rid of the Link to the external data source on the copied
pages?

TIA
Candyman







Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Creating new link to external data (ODBC) Kristibaer Excel Discussion (Misc queries) 1 May 13th 09 06:21 PM
Breaking external Links Red Excel Discussion (Misc queries) 1 March 6th 09 02:29 AM
Import external data link disappears DataFlunky Excel Worksheet Functions 1 February 17th 09 04:55 PM
Corupt external data link RyanLennard Excel Discussion (Misc queries) 0 June 4th 07 03:00 PM
Hidden external data link Geoff Lambert Excel Discussion (Misc queries) 4 November 27th 06 02:58 PM


All times are GMT +1. The time now is 06:54 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"