Weekly I am replacing old data with new data in an Excel 2000 worksheet. Through this forum I learned about using the refresh method. This is the code I recorded to do it:
Application.Goto Reference:="VacationInfo"
Selection.QueryTable.Refresh BackgroundQuery:=False
(I expected to see a connection to a file path).
The question is: Apparently Excel is using a SQL query (that it created) to connect to my external .txt file (where I get the data from) correct? Am I able to look at that query or edit it? If the file gets moved to another directory I am wondering if Excel will still be able to find it. I don't really understand how Excel found the file because all I did is record the menu choices, Data, and Refresh Data (I didn't navigate to my file).
Thanks,
Sharon
Application.Goto Reference:="VacationInfo"
Selection.QueryTable.Refresh BackgroundQuery:=False
(I expected to see a connection to a file path).
The question is: Apparently Excel is using a SQL query (that it created) to connect to my external .txt file (where I get the data from) correct? Am I able to look at that query or edit it? If the file gets moved to another directory I am wondering if Excel will still be able to find it. I don't really understand how Excel found the file because all I did is record the menu choices, Data, and Refresh Data (I didn't navigate to my file).
Thanks,
Sharon