PDA

Click to See Complete Forum and Search --> : I NEED SQL HELP HERE PLEASE!!


santiagope2000
Jun 27th, 2000, 10:49 AM
I am able to connect using ADO and can get the results to popup on the debug window However I still can't get data to popup up on an array of Text fields. Please help

Private Sub Command1_Click()
Dim Conn As New ADODB.Connection
Dim cmd As New ADODB.Command
Dim rs As ADODB.Recordset
Dim sConnString As String
Dim iCtr As Integer

sConnString = "Provider=SQLOLEDB.1;User ID=sa;password=;Initial Catalog=myfirstdatabase;Data Source = SQLDEVSRV001;Use Procedure for Prepare=1;Auto Translate=True;Packet Size=4096"
Conn.Open sConnString
Set cmd.ActiveConnection = Conn
cmd.CommandText = "SELECT name FROM mypeople WHERE name = 'Jimmy'"
cmd.CommandType = adCmdText
Set rs = cmd.execute

<WHAT AM I MISSING????>

Set rs = Nothing
Set cmd = Nothing
Conn.Close
Set Conn = Nothing

Clunietp
Jun 27th, 2000, 12:03 PM
it all looks fine, you just have to manipulate your RS now

do that where you put:
<WHAT AM I MISSING????>