Below is my worksheet called 'List'
name tel address
----- --- --------
Rick 1325689 Flat A
Hanry 7885654 Room 7
Rockman 7775432 House 200
===================================
Below is my excel vba code
----------------------------------------------
strQuery = "SELECT * FROM[List$]"
Set rs = cn.Execute(strQuery)
strStartlocation = "A1"
Dim lngColCounter As Long
For lngColCounter = 0 To rs.Fields.Count - 1
Range(strStartlocation).Offset(0, lngColCounter) = rs.Fields(lngColCounter).Name
Next lngColCounter
ActiveSheet.Range(strStartlocation).Offset(1, 0).CopyFromRecordset rs
---------------------------------------------------
I can success to show all table information
I want to know how to select and display specific data
For example, How to display "7775432"
Bookmarks