to show a recordset as table
- From: "michele de meo" <micheledemeo@xxxxxxxxx>
- Date: 19 Jul 2006 05:40:35 -0700
use this vba code after to connect Access to a remote db. I obtain a
recorset and I want to show it as "table". I bind this recordset to a
form, but how to show as table?
This is the code (associated to a clik of a command botton):
Set recSet = New ADODB.Recordset
With recSet
Set .ActiveConnection = con 'con is the connection
defined above in the code
.Source = "select var1 from datamart where rix=4"
.LockType = adLockBatchOptimistic
.CursorType = adOpenKeyset
.CursorLocation = adUseClient
.Open
End With
Set Me.Recordset = recSet
After this code I correctly bind the recordset to the form , and if I
set the Form to "spread***", I obtain a table with the just number of
records but without fields......
Someone could hel me?
thanks
michele de meo
.
- Follow-Ups:
- Re: to show a recordset as table
- From: pietlinden
- Re: to show a recordset as table
- Prev by Date: Re: SQL Server, expressions can call code in modules??
- Next by Date: Re: Can I use the data in one field as a variable in the other?
- Previous by thread: parameterised view sql express 2005
- Next by thread: Re: to show a recordset as table
- Index(es):