May 2, 2005 at 2:23 pm
May 2, 2005 at 2:25 pm
What is the question?
May 2, 2005 at 2:29 pm
I would like to pass a value from an Access adp project form to a parameter in a stored procedure is this possible and if so how?? The old =Forms!myform!mytextbox doesn’t work
May 2, 2005 at 2:39 pm
in the form source use dbo.ProcedureName
and in input parameters : Forms!myform!mytextbox
then separate each parameter with a comma.
May 3, 2005 at 8:08 am
Here is my code for the stored procedure
Start code:
Alter
Procedure "sp_GetVar"
(
@FormVar nvarchar
(20)
)
As
SELECT
JobName, Version, [Version count], Comments,
[envelope size], [complete date], [mail class], AssignmentFirst,
[sort order], AssignmentSecond, ShipOrder
FROM
dbo.AutoVersionSource
where
JobName = @FormVar
End code:
It runs fine and returns the correct results, if I add the "@FormVar nvarchar(20)=Forms!myform!myvalue" it kicks at the"!"s
May 3, 2005 at 8:44 am
You can't include Forms!myform!myvalue in the proc code.
You must create a new form
set the data source of the form to dbo.ProcedureName
then in input parameters you must set it to Forms!myform!myvalue
May 3, 2005 at 1:03 pm
Okay I got it, thanks! Here are the steps for others to follow:
User selects what they want from the list box, clicks the button and the desired results are viewed in the second form.
Viewing 7 posts - 1 through 6 (of 6 total)
You must be logged in to reply to this topic. Login to reply