Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 26
Default And the answer is ... MaintainConnection

I seem to have things working now.
The MaintainConnection property of QueryTable lets my people go.

Here is the code that ultimately did the trick:


With Selection.QueryTable
.Connection = MyConnectString1 & Range("Folder") & Range("FileName")
& MyConnectString2
.CommandType = xlCmdSql
.CommandText = Array(SqlStatement)
.MaintainConnection = False
.Refresh BackgroundQuery:=False
End With

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
How to Start Excel in Text Import Wizard for data import rlelvis Setting up and Configuration of Excel 0 July 10th 08 08:40 PM
Import external data, data includes Excel function allen davidson Excel Worksheet Functions 0 July 4th 08 12:39 PM
Import Data / Edit Data / Export Data in Excel Mathias Fritsch Excel Programming 0 July 19th 07 04:08 PM
PLEASE!! How can I un-grey the 'Data-Import External Data-Import Data' option ??? kirkm[_6_] Excel Programming 13 August 8th 06 10:01 AM
how to Import data in excel office2003 with data more 65000 rows Abhijit Excel Worksheet Functions 1 May 13th 05 05:12 AM


All times are GMT +1. The time now is 12:33 AM.

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

About Us

"It's about Microsoft Excel"