Ask a Question related to ASP.NET General, Design and Development.
-
blenderdude #1
Re: now desparate! - 1st listbox contents disappears when 2nd listbox appears?
On 23 Jun 2003 12:57:45 -0700, [email]KathyBurke40@attbi.com[/email] (KathyB) wrote:
Its been a while since you posted but I will answer anyway. The>Hi, I'm back.
>
>I have two dropdownlist server controls. #1 populates on pageload -
>works fine.
>#2 also populates fine (on #1 selecteditemchanged event).
>
>My problem is that I need to RETAIN the value selected in #1 so the
>user sees it, and also I will need to capture it as a variable to pass
>on to the next pages reload...I though ViewState did that for me, but
>doesn't appear to be working.
>
>I have #1 set to viewstate = true and autopostback = true.
>
>I've set the code to be If Not IsPostBack, etc. Could someone PLEASE
>tell me where I'm going wrong and/or how to accomplish the above? Code
>follows.
>
>Thanks! Kathy
problem is on the following two lines. You are binding the entire form
and the will reset the users selection on the listbox.Instead you should only bind that particular listbox, as in:> Me.DataBind()
> Me.DataBind()
listbox1.databind
listbox2.databind
that way the second databind won't affect the users selection in the
first textbox.
Mike
blenderdude Guest
-
xml to combobox, combobox to listbox, listbox todetails
i am going out of my mind looking for a tutorial i am able to use a xml document and the xml connector component to populate a pulldown menu, i... -
listbox to populate a listbox
I am trying to use a listbox that I have setup using flash remoting call to a db. What I want to happen is when you click on a item in first the... -
click listbox and refresh another listbox
Can someone guide me to a resource on building set of drill-down listboxes? Basically I want to have 4 listboxes. The first starts out with... -
Item label displays as "," when moving from listbox to listbox
I have 2 listboxes: "lb_unselected" and "lb_selected". The first thing in the actions is loop through an array populating these two listboxes. ... -
listbox help
i need majke a menu with listbox, and i donīt know how please post a sample



Reply With Quote

