Home All Groups Group Topic Archive Search About
Author
23 May 2005 12:53 PM
K R Lal
Hi,

Any idea how to fill a dropdownlist thru dataset

I done like this
ddLst1.DataSource = myDataSet
ddLst1.DataMember = myDataSet.Tables(0).Columns(1).Caption

ddLst1.DataValueField = myDataSet.Tables(0).Columns(0).Caption

but it is not working ; my dropdown list showing blanck

please help me
--
Regards

K R Lal

Author
23 May 2005 4:55 PM
Andrew Robinson
Already answered in another group. avoid cross-posting.

you need to call the DataBind() method.

-Andrew

Show quoteHide quote
"K R Lal" <l***@yahoo.com> wrote in message
news:ubrjKZ5XFHA.1152@tk2msftngp13.phx.gbl...
> Hi,
>
> Any idea how to fill a dropdownlist thru dataset
>
> I done like this
> ddLst1.DataSource = myDataSet
> ddLst1.DataMember = myDataSet.Tables(0).Columns(1).Caption
>
> ddLst1.DataValueField = myDataSet.Tables(0).Columns(0).Caption
>
> but it is not working ; my dropdown list showing blanck
>
> please help me
> --
> Regards
>
> K R Lal
>
>