From: tshad on
We have a situation that is a little strange.

We have a DropDownList which has 8 items the values are 0-7.

If we do:

cboLocation.Selected = "0";

This works the first time but the second time we do that we get an error:

"'cboLocation' has a SelectedValue which is invalid because it does not
exist in the list of items.\r\nParameter name: value"

In the debugger, you can see that all the values are still there (including
"0").

Now if I change the value to "3", I can do it 10 times and no error. If I
change it back to "0", I get the error again.

Why is that????

Thanks,

Tom


From: stanlj on
Tried to duplicate your problem and could not. Also my DropDownList does not
not have a Selected property tho if there was one, i would think that would
be take a true/false value. Did u ever figure this out?

"tshad" wrote:

> We have a situation that is a little strange.
>
> We have a DropDownList which has 8 items the values are 0-7.
>
> If we do:
>
> cboLocation.Selected = "0";
>
> This works the first time but the second time we do that we get an error:
>
> "'cboLocation' has a SelectedValue which is invalid because it does not
> exist in the list of items.\r\nParameter name: value"
>
> In the debugger, you can see that all the values are still there (including
> "0").
>
> Now if I change the value to "3", I can do it 10 times and no error. If I
> change it back to "0", I get the error again.
>
> Why is that????
>
> Thanks,
>
> Tom
>
>
> .
>