|
-
Mar 8th, 2001, 12:20 PM
#1
Thread Starter
Junior Member
Hi,
I have been trying to do this for a couple days now... it seems easy, but it's not.
This is what I have and know:
My database is in SQL Server 7
My application is in VB6
I am working on creating a Report.
Did:
-Set up a DataEnvironment command which uses a stored procedure that has a Parameter.
-Set up a report design.
-Have a form where I ask the user to choose a value from a drop down list to be used as a value for a parameter of the stored procedure.
On the click event of OK button of the form I have this:
strProgramID = cmbJobsPrograms.ItemData(cmbJobsPrograms.ListIndex) -->gets value chosen by the user from cmbJobsPrograms
deCCDB.comParticipantsHistory (strProgramID) --> assign (or try to assign) value to the parameter.
deCCB = data environment
comParticipantsHistory = command that holds the stored procedure
rptParticipantHistory.Show
The problem is: I get an error saying that "No value given for one or more parameters"
I tried playing with the data types on the parameters tab of the command object in the data environment, but I started getting data types errors.
What am I doing wrong??? Is there another way???
How do I pass a value from a form to be used as a parameter in a stored procedure??
PLEASE HELP!!!!!!
Juls.
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
|