|
-
May 11th, 2001, 07:53 AM
#1
why does this only returns the first field
Hi,
if got a little testing-database with about 20 recordsets into it. i want them to be read out but the code below gives only the first recordset in the fieldproperty. what have i done wrong?
thanks
akademos
private Sub Form_Load()
Dim sql as string
sql = "select * from roman"
set theRecordset = new ADODB.Recordset
theConn.ConnectionString = "Provider = SQLOLEDB.1;Initial Catalog = PerryRhodanEnt;User ID =sa"
theConn.Open
theRecordset.Open sql, theConn, adOpenKeyset, adLockOptimistic, adCmdText
for Each Field In theRecordset.Fields
If Not (IsNull(Field.Value)) then
MsgBox Field.Value
End If
next
End Sub
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|