This is a Stored Procedure:
ALTER PROCEDURE [dbo].[Proc_ins_Colaboradores]
varchar(80),
Datetime,
Char(1),
Varchar(18),
Varchar(30),
int,
char(1),
int,
int OUTPUT
AS
BEGIN
SET NOCOUNT ON;
INSERT tbl_Colaboradores (str_Nome.........
This is my VB Code:
l_cmm_Comando.Connection = l_cnn_Conexao
l_cmm_Comando.CommandText = "proc_ins_Colaboradores"
l_cmm_Comando.CommandType = CommandType.StoredProcedure
l_cmm_Comando.Parameters.AddWithValue(
, str_Nome)
l_cmm_Comando.Parameters.AddWithValue(
, dat_Nascimento)
l_cmm_Comando.Parameters.AddWithValue(
, str_EstadoCivil)
l_cmm_Comando.Parameters.AddWithValue(
, str_Nacionalidade).......
All be DateTime Type, I make a test and put the fixed line in vb code:
l_cmm_Comando.Parameters.AddWithValue(
, cdate(Now()))
or
l_cmm_Comando.Parameters.AddWithValue(
, Now())
...And I receive the same error:
error converting data type nvarchar to int
Thanks for help !
|