how do i directly edit a connection string in an Excel workbook q.

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

i need to edit a connection string due to a corporate change in servers.

this change does not allow the query editor(s) to open the query through the
standard Excel defaults.

i'm hoping someone will know a way to edit the connectstring.

thanks!
 
The QueryTable.Connection property contains the connection string; I have
never tried changing the connection db this way but it should be possible, I
would go into the immediate pane and try this:

? Sheets("SheetName").QueryTables(1).Connection
- to see what the current string looks like

Sheets("SheetName").QueryTables(1).Connection = "... "
To reset the connection parameters
 
Thanks,
this did allow me to reconnect. this allowed almost all queries to run
again. the only one that didn't just needed to be relinked.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top