Re: strange question about DropDownList



>From what I see, the value you provide in the "lev" column is neither
"test1" nor is it "test2", have you checked your SQL? Perhaps you've got
different data in you SQL Server database than you had in the Access
database.

HTH,
Axel Dahmen


--------------
"Detective" <Detective@xxxxxxxxxxxxxxxxxxxxxxxxx> schrieb im Newsbeitrag
news:4B9B5D8B-9352-4F9D-8760-5EF89ACCA147@xxxxxxxxxxxxxxxx
> hi:
> when i used code below and bind with access i could get the resoult what
i
> want, but when i use sqlserver i got an exception about
> System.ArgumentOutOfRangeException which argument is lev.how can i solve
this
> problem ,thank you:)
>
////////////////////////////////////////////////////////////////////////////
///////////
> <asp:DropDownList id="DropDownList2" Width="144px"
> SelectedValue='<%#DataBinder.Eval(Container.DataItem, "lev")%>'
Runat=server
> >
> <asp:ListItem>test1</asp:ListItem>
> <asp:ListItem>test2</asp:ListItem>
> </asp:DropDownList>


.



Relevant Pages