Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Development Tools
 ASP.NET
 Refreshing the DropDown Combo Box

Author  Topic 

vk18
Posting Yak Master

146 Posts

Posted - 2006-11-13 : 13:54:07
Hi,
I have 6 text boxes and 1 dropdown combo on a form. I put a command button next to dropdown. when i click on that cmdbutton
i want to refresh just the drop down combo NOT ALL the text boxes on the form. I added the code

me.dropdow.autopostback = true

But it is not working. Any Idea..? I am using VB.NET/ASP.NET

Thx

MichaelP
Jedi Yak

2489 Posts

Posted - 2006-11-13 : 20:05:09
To do that, I think you'll need to use AJAX. Do some serching on AJAX and ATLAS.

http://ajax.asp.net/default.aspx?tabid=47

Michael

<Yoda>Use the Search page you must. Find the answer you will. Cursors, path to the Dark Side they are. Avoid them, you must. Use Order By NewID() to get a random record you will.</Yoda>

Opinions expressed in this post are not necessarily those of TeleVox Software, inc. All information is provided "AS IS" with no warranties and confers no rights.
Go to Top of Page

vk18
Posting Yak Master

146 Posts

Posted - 2006-11-15 : 13:32:38
Hi,

I think there is a simple way to refresh just the drop down can some body give me an idea..?
Thx
Go to Top of Page

MichaelP
Jedi Yak

2489 Posts

Posted - 2006-11-15 : 16:56:33
AJAX is the simpliest way I know of.

Michael

<Yoda>Use the Search page you must. Find the answer you will. Cursors, path to the Dark Side they are. Avoid them, you must. Use Order By NewID() to get a random record you will.</Yoda>

Opinions expressed in this post are not necessarily those of TeleVox Software, inc. All information is provided "AS IS" with no warranties and confers no rights.
Go to Top of Page

DotNetMaster
Starting Member

35 Posts

Posted - 2006-11-15 : 19:18:15
Most dot net controls by default perform a post back to the server.
Set AutoPostback to false for those "other" fields.

You could use JS / AJAX combination if you want to refresh the list and not have to worry about the post back as MichaelP stated.
Go to Top of Page
   

- Advertisement -