Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Deleting Web Query Problem

I have a web query that is added programmatically. When it is added, th
code specifies its name. If the name already exists, excel appends
_1 (or whatever number its on)

Now, even if I delete all the query defintions and all of the rang
names with the following code,

For Each qt In ActiveSheet.QueryTables
qt.Delete
Next qt
For Each n In ActiveSheet.Names
n.Delete
Next n

And re-run the macro that adds the query, it still gives me the _1
Yet, If I close the workbook, and re-open it, and then run the macro
it creates the query without the _1 ...

So my question is, how do I clear all reminents of a query tabl
without having to reload the workbook (i.e. What am I missing othe
than clearing the range name and the query table?)

--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Deleting Web Query Problem

(Sry about the multiple posts o_O, dont know what happened

--
Message posted from http://www.ExcelForum.com

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
another macro query - deleting a worksheet within a query DavidHawes Excel Discussion (Misc queries) 2 February 26th 07 10:05 AM
Problem with MS Query - can't edit query jarems Excel Discussion (Misc queries) 2 December 12th 05 09:42 AM
deleting a macro resulted in a problem militant Excel Discussion (Misc queries) 0 April 26th 05 05:21 AM
Deleting a query Rhonda[_3_] Excel Programming 1 December 4th 03 10:47 PM
Row deleting script problem jessica Excel Programming 1 October 15th 03 11:55 AM


All times are GMT +1. The time now is 10:46 PM.

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"