Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Executing stored procedures from adp 1

Status
Not open for further replies.

TommyTea

Programmer
Nov 7, 2002
43
US
I am writing my first adp and I am trying to figure out the best way to execute a SQL Server stored procedure where the parameters are supplied from combo boxes.
 
Dim prm As ADODB.Parameter
Dim cmd As ADODB.Command

Set cmd = New ADODB.Command
Set cmd.ActiveConnection = CurrentProject.Connection
cmd.CommandText = "sp_860Prompt"
cmd.CommandType = adCmdStoredProc

'cmd.Parameters(0).Type = adVarChar
cmd.Parameters(1).Direction = adParamInput
cmd.Parameters(2).Direction = adParamInput
cmd.Parameters(1).Value = strCust
cmd.Parameters(2).Value = dtmDate

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top