Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Weird problem
Message
 
 
To
All
General information
Forum:
ASP.NET
Category:
Other
Title:
Weird problem
Environment versions
Environment:
C# 3.0
OS:
Windows XP
Database:
MS SQL Server
Miscellaneous
Thread ID:
01327334
Message ID:
01327334
Views:
59
Hi everybody,

I've added one more parameter to my SQLDataSource (I'm using stored procedure). This new parameter is output parameter.

I'm getting this strange error
System.InvalidOperationException: String[0]: 
the Size property has an invalid size of 0. at 
System.Data.SqlClient.SqlParameter.Validate(Int32 index, Boolean isCommandProc) at System.Data.SqlClient.SqlCommand.
SetUpRPCParameters(_SqlRPC rpc, Int32 startCount, Boolean inSchema, SqlParameterCollection parameters) 
Nothing is sent to SQL Server ('m checking this info in the SQL Profiler).

Do you know what could be wrong?

Here is the definition in the Page:
<InsertParameters>
                <asp:Parameter Name ="NewPersonID" Direction ="Output" /> 
                <asp:Parameter Name="Title" />
                <asp:Parameter Name="Occupation" />
                <asp:Parameter Name="BusinessName" />
                <asp:Parameter Name="BusAdd1" />
                <asp:Parameter Name="BusAdd2" />
                <asp:Parameter Name="BusCity" />
                <asp:Parameter Name="BusState" />
                <asp:Parameter Name="BusZip" />
                <asp:Parameter Name="Pager" />
                <asp:Parameter Name="Fax" />
                <asp:Parameter Name="BusinessPhone" />
                <asp:ProfileParameter Name="SiteID" PropertyName="SiteID" Type="Int32" />
                <asp:QueryStringParameter Name="PType" QueryStringField="ptype" Type="Char" DefaultValue ="N" />
                <asp:ControlParameter ControlID="PeopleNoneForm$ddlGender" Name="Gender" PropertyName="SelectedValue" />
                <asp:Parameter Name="SpouseFN" />
                <asp:Parameter Name="SpouseLN" />
                <asp:Parameter Name="SpouseID" />
                <asp:Parameter Name="Anniversary" />
            </InsertParameters>
Do you see what could be wrong?

Thanks in advance.
If it's not broken, fix it until it is.


My Blog
Next
Reply
Map
View

Click here to load this message in the networking platform