Forum Discussion
I'm trying to execute following command
exec ZipStoreConversions @ProductId=N'GMVE 000057',@ParameterCollectionID=N'FH',@ConvertToProduct=N'VIT 000100',@ConvertFromProduct=N''
parameters definiod from stored procedure
@ProductID varchar(11),
@ParameterCollectionID varchar(50),
@ConvertToProduct varchar(11),
@ConvertFromProduct varchar(11)
I use following code - it always give me error in line
param1["DataType"] = DB["adVarChar"];
"Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another"
Do I do something wrong?
Cmd["CommandText"]= "dbo.ZipStoreConversions"
Cmd["CommandType"] = DB["adCmdStoredProc"];
var param1 = Cmd["Parameters"]["AddParameter"]();
param1["Name"] = "ProductId";
param1["DataType"] = DB["adVarChar"];
param1["Direction"] = DB["adParamInput"];
param1["Value"] = "GMVE 000057";
var param2 = Cmd["Parameters"]["AddParameter"]();
param2["Name"] = "ParameterCollectionID";
param2["DataType"] = DB["adVarChar"];
param2["Direction"] = DB["adParamInput"];
param2["Value"] = "FH";
var param3 = Cmd["Parameters"]["AddParameter"]();
param3["Name"] = "ConvertToProduct";
param3["DataType"] = DB["adVarChar"];
param3["Direction"] = DB["adParamInput"];
param3["Value"] = "VIT 000100";
var param4 = Cmd["Parameters"]["AddParameter"]();
param4["Name"] = "ConvertFromProduct";
param4["DataType"] = DB["adVarChar"];
param4["Direction"] = DB["adParamInput"];
param4["Value"] = "";
RecSet = Cmd["Execute"]();
Related Content
Recent Discussions
- 3 days ago
- 3 days ago
- 6 days ago