ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   get data and field name using querytables (https://www.excelbanter.com/excel-programming/376341-get-data-field-name-using-querytables.html)

x taol

get data and field name using querytables
 
Set rs = db.OpenRecordset("select * from tbl")
Set qt = sht.QueryTables.Add(rs, sht.[a1])
qt.Refresh 1

in that case, field name occur, that good. but a name is
made(ex:ExternalData1), that no good. And CopyFromRecordset method
doesn't bring the field name.

i want to write in that sheet with only data and field name using
querytables.



*** Sent via Developersdex http://www.developersdex.com ***


All times are GMT +1. The time now is 01:29 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com