Re: Strange WebForms behavior in Visual Studio .NET 2003
From: Popeye 'Bailo' Doyle (jabailo_at_earthlink.net)
Date: 03/01/04
- Next message: Ari Kukkonen: "vs2003 .net -> c++ 6.0"
- Previous message: Popeye 'Bailo' Doyle: "Strange WebForms behavior in Visual Studio .NET 2003"
- In reply to: Popeye 'Bailo' Doyle: "Strange WebForms behavior in Visual Studio .NET 2003"
- Messages sorted by: [ date ] [ thread ]
Date: Mon, 01 Mar 2004 23:57:13 GMT
Popeye 'Bailo' Doyle wrote:
> I'm experiencing some strange behavior in Visual Studio .NET 2003
>
> I developed a WebForm with 6 text entries, each with a set of two radio
> buttons, a drop down list and a checkbox.
>
> I want to set the drop down list or the checkbox to appear based on
> which radio button is selected...and initially I want both to be not
> visible.
>
> So, in the webform designer I set the visible property to false.
>
> Then, I double clicked on each radio button and set their CheckedChanged
> events to make the elements visible or not.
>
>
> When I run the page in debug mode:
>
> (a) The visible property does not seem to take effect. All the form
> elements are visible.
>
> (b) The CheckedChanged event doesn't seem to fire.
>
> (c) I did a view source. The odd thing is that the order in which all
> these elements are displayed in the HTML does not match the order that
> they are displayed in the webform designer in studio.
>
> I took each element and gave it a name and number, like TextBox1. In
> the displayed HTML the items appear in the reverse order of Textbox6,
> TextBox5 and so on.
>
> What could possibly do that ????
Ok, I think I solved it.
There were a bunch of controls ( duplicates ) under the first set of
controls which I copied in bunches.
Then...the trick to radio buttons dynamically affecting the web page is
to set AutoPostBack to /true/
I'm not sure I like the effect compared to client side javascript, but
at least it does the trick.
- Next message: Ari Kukkonen: "vs2003 .net -> c++ 6.0"
- Previous message: Popeye 'Bailo' Doyle: "Strange WebForms behavior in Visual Studio .NET 2003"
- In reply to: Popeye 'Bailo' Doyle: "Strange WebForms behavior in Visual Studio .NET 2003"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|