Ian A
5/13/2002 10:15:00 AM
solved it, forgot to put 'if not ispostback then/endif round my pageload
code.
Ian
"Ian A" <ian@addinsell.co.uk> wrote in message
news:upF7fOd#BHA.2524@tkmsftngp05...
> I have a form with a selectionlist control and a command button
>
> The selectionlist is bound to a SQL query which returns a list of dates
and
> formatted dates ( eg. 05/12/2002, Sun 12 May ) I have set the
datatextfield
> and datavaluefield to the query field names and I can show either of
those
> in the control fine.
>
> I have code attached to the 'SelectedIndexChanged' event and this is
> triggered when I click the command button. I can't seem to read back the
> chosen item in the dropdown list that is shown on the page.
>
> My code ans = selectionlist1.selection.value reports
> 'System.NullReferenceException: Object reference not set to an instance of
> an object.'
>
> What am I overlooking?
>
> Thanks
> Ian
>
>