USE [Sams]
GO
/****** Object: StoredProcedure [dbo].[AddRegistrationFormNew] Script Date: 07/29/2013 09:46:50 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
ALTER PROCEDURE [dbo].[AddRegistrationFormNew]( @Name VARCHAR(15),@Address VARCHAR(30),@PhoneNumber INT,@EmailId VARCHAR(15))
AS
declare @Rid as int
select @Rid =ISNULL( max(Rid),0)from AddRegistrationFormNew
set @Rid=@Rid+1;
INSERT INTO RegistrationFormNew(Rid,Name,Address,PhoneNumber,EmailId)VALUES(@Rid,@Name,@Address,@PhoneNumber,@EmailId)
EXEC AddRegistrationFormNew 'test','palak','100','[email protected]'

Ravi ShekharPosted Jul 29, 2013, 3:28 AM
mohammed shamsheerPosted Jul 29, 2013, 2:17 AM
so i used convert.toINT#32
{ "@PhoneNumber", Convert.ToInt32(txtPhoneNumber.Text) }
thank u for the all the answer
Ravi ShekharPosted Jul 29, 2013, 1:07 AM
EXEC AddRegistrationFormNew 'test','palak','100','[email protected]'
thats y you are getting error.
use Iftikar Hussain sir code.
Iftikar HussainPosted Jul 29, 2013, 12:40 AM
try like this
EXEC AddRegistrationFormNew 'test','palak',100,'[email protected]'
Regards,
Iftikar