Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
290
Help with binding WebDropDown to a linq query
posted

Could someone help:

     I have a WebDropDown via the 'NetAdvantage 10.3 ASP.NET CLR4X' that I am trying to bind to a Linq to sql query that returns a IEnumerable.  The problem I am incurring is the values displayed in the webDropDown end up looking funny.  The have curly brackets around them and each display value has ID=value.  ie:  { ID=A/G}, {ID=A/M},{ID=A/N} etc.  The values should be A/G,A/M,A/N.  What am I doing wrong?

Here is the function used to get the IEnumerable from my Dataclass.

Normal 0 false false false EN-US X-NONE X-NONE MicrosoftInternetExplorer4

Normal 0 false false false EN-US X-NONE X-NONE MicrosoftInternetExplorer4

Normal 0 false false false EN-US X-NONE X-NONE MicrosoftInternetExplorer4


    Public Function Get_WharehouseID() As IEnumerable
        Return (From w In db.WarehouseIDs Select New With {.ID = w.WhseID}).OrderBy("ID", ASCENDING)
    End Function

Normal 0 false false false EN-US X-NONE X-NONE MicrosoftInternetExplorer4

<ig:WebDropDown ID="wddWarehouse" runat="server" Width="200px"> </ig:WebDropDown>

 

I am binding the WebDropDown as follows:

Normal 0 false false false EN-US X-NONE X-NONE MicrosoftInternetExplorer4

Normal 0 false false false EN-US X-NONE X-NONE MicrosoftInternetExplorer4

wddWarehouse.EnableMultipleSelection = True

wddWarehouse.MultipleSelectionType = DropDownMultipleSelectionType.Keyboard

Dim objData As New DataLinq

wddWarehouse.DataSource = objData.Get_WharehouseID

wddWarehouse.DataBind()

 

 

Parents
No Data
Reply Children
No Data