G
Guest
Hi,
This is my stored procured. i try to pass the parametre like this. i am
getting error.
any one please tell me how to pass the parameter?
vb code:
..Connection = New OleDbConnection(strConn)
..Connection.Open()
..CommandText = "sp_RegShow1"
..Parameters.Item(1).Value = Replace(Trim(Mid(cboCustName.Text, 1,
InStr(cboCustName.Text, "-") - 1)), "'", "~")
..Parameters.Item(2).Value = Replace(Trim(Mid(cboCustName.Text, 1,
InStr(cboCustName.Text, "-") - 1)), "'", "~")
thanks
bala
Stored procedure:
CREATE PROCEDURE [dbo].[sp_RegShow1]
(@FirstName_1 [nvarchar](50),
@LastName_1 [nvarchar](50)
)
AS
select * from tbleusers where firstname=@FirstName_1 and lastname=@LastName_1
GO
This is my stored procured. i try to pass the parametre like this. i am
getting error.
any one please tell me how to pass the parameter?
vb code:
..Connection = New OleDbConnection(strConn)
..Connection.Open()
..CommandText = "sp_RegShow1"
..Parameters.Item(1).Value = Replace(Trim(Mid(cboCustName.Text, 1,
InStr(cboCustName.Text, "-") - 1)), "'", "~")
..Parameters.Item(2).Value = Replace(Trim(Mid(cboCustName.Text, 1,
InStr(cboCustName.Text, "-") - 1)), "'", "~")
thanks
bala
Stored procedure:
CREATE PROCEDURE [dbo].[sp_RegShow1]
(@FirstName_1 [nvarchar](50),
@LastName_1 [nvarchar](50)
)
AS
select * from tbleusers where firstname=@FirstName_1 and lastname=@LastName_1
GO