Good morning,
I have a data enviroment set up in my VB6 project with a stored procedure that I am calling within a form in the same project. The stored procedure that I am calling passes four values and returns two.
Example:
Create procedure upDateTable (@intValue1 int, @sValue2 char(6) output, @intValue3 int Output, @sValue char(10))
I can run the stored procedure from the Query Analyzer with no problems so I know that I it not a SQL/Stored Procedure problem.
The values that I pass are in order - 1,'345674',5,'SAMPLE'
After testing the call from my VB project to the store procedure ( by modifying the stored proc to not return values and then by only returning a value one at a time ) , I was able to determine that it was the @sValue2 char(6) output that was causing the error. For some reason, my project does not except the return value of the stored procedure. Again, I know it is not the stored procedure.
The complete error I get is : 'Arguments are of the wrong type, are out of acceptable range , or are in conflict with one another.
I have the variable that I am originally passing to the stored procedure declared as a string in my project.
I have stepped through it with the Debugger and the value that I am passing '345674' returns as the same value or another string. I have even added print statements when I run it to make sure that my debugger was correct. I am not returning a integer or a Null when I get the error in Visual Basic.
Is there something that I am not setting in the properties of the stored procedure in the Data Environment? Right now, I have just the defaults as I am not returning a recordset but only the output values.
Thanks for any help,
KFlasph
I have a data enviroment set up in my VB6 project with a stored procedure that I am calling within a form in the same project. The stored procedure that I am calling passes four values and returns two.
Example:
Create procedure upDateTable (@intValue1 int, @sValue2 char(6) output, @intValue3 int Output, @sValue char(10))
I can run the stored procedure from the Query Analyzer with no problems so I know that I it not a SQL/Stored Procedure problem.
The values that I pass are in order - 1,'345674',5,'SAMPLE'
After testing the call from my VB project to the store procedure ( by modifying the stored proc to not return values and then by only returning a value one at a time ) , I was able to determine that it was the @sValue2 char(6) output that was causing the error. For some reason, my project does not except the return value of the stored procedure. Again, I know it is not the stored procedure.
The complete error I get is : 'Arguments are of the wrong type, are out of acceptable range , or are in conflict with one another.
I have the variable that I am originally passing to the stored procedure declared as a string in my project.
I have stepped through it with the Debugger and the value that I am passing '345674' returns as the same value or another string. I have even added print statements when I run it to make sure that my debugger was correct. I am not returning a integer or a Null when I get the error in Visual Basic.
Is there something that I am not setting in the properties of the stored procedure in the Data Environment? Right now, I have just the defaults as I am not returning a recordset but only the output values.
Thanks for any help,
KFlasph