Hi all![]()
I have this codeVB Code:
Private Sub Form_Load() ' **** Create Connection and Recordset Objects **** Dim cnConn As ADODB.Connection Dim rs As ADODB.Recordset Dim strsql As String ' **** Instantiate the new objects **** Set cnConn = New ADODB.Connection Set rs = New ADODB.Recordset ' **** Set up connection String **** With cnConn .Provider = "SQLOLEDB.1" .Properties("Data Source").Value = "www" .Properties("User ID").Value = "clroot" .Properties("Password").Value = "clroot" .Properties("Initial Catalog").Value = "iosif" .CursorLocation = adUseClient .ConnectionTimeout = 0 .Open End With ' **** String to pass to the connection to get records back **** strsql = "select * from salesman" ' **** Open Records for readonly **** rs.Open strsql, cnConn, adOpenStatic, adLockReadOnly
How I can pass values from table salesman into a datareport1?![]()
thank you
Edit: Added [vbcode][/vbcode] tags for more clarity. - Hack




Reply With Quote