Querytables.add with sql query text stored in separate text file
Hi Joel
Thanks for your prompt reply. Do I need to tick a reference library
(Tools References in the VBE) to use the code I've quoted below as
OpenTextFile, ReadFile, ForReading and TristateTrue are not recognised
methods/properties in my VBE?
Set fs = CreateObject("Scripting.FileSystemObject")
Set fin = fs.OpenTextFile(ReadFile, _
ForReading, TristateTrue)
Kind regards
Stuart
|