473,324 Members | 2,193 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,324 software developers and data experts.

cascade change other control based on dropdownlist control changes

Hi,

I have a dropdownlist control and a few textbox on my web form. How can I
update those textbox content when user select item from dropdownlist control?
I really want to do this on client side so that don't need back to server.
Thanks.

william

Nov 19 '05 #1
3 1758
Hi William
in the property of dropDownList make AutoPostBack=true
and in the events of dropDownList.selectIndexChange write ur code
"william" wrote:
Hi,

I have a dropdownlist control and a few textbox on my web form. How can I
update those textbox content when user select item from dropdownlist control?
I really want to do this on client side so that don't need back to server.
Thanks.

william

Nov 19 '05 #2
William,

Basically, you just need to operate on DHTML objects corresponding to your
page elements. A ddl renders as an html <select> element and a textbox
renders as <input type="text">. You need to setup a client site javascript
onchange event handler for the dll that will get the selected text or value
and populate the textboxes.

Use Attributes["onchange"] = "onDllChange()" to setup the event.

Eliyahu

"william" <wi*****@discussions.microsoft.com> wrote in message
news:79**********************************@microsof t.com...
Hi,

I have a dropdownlist control and a few textbox on my web form. How can I
update those textbox content when user select item from dropdownlist control? I really want to do this on client side so that don't need back to server.
Thanks.

william

Nov 19 '05 #3
Hi Eliyahu,
Thanks.
william

"Eliyahu Goldin" wrote:
William,

Basically, you just need to operate on DHTML objects corresponding to your
page elements. A ddl renders as an html <select> element and a textbox
renders as <input type="text">. You need to setup a client site javascript
onchange event handler for the dll that will get the selected text or value
and populate the textboxes.

Use Attributes["onchange"] = "onDllChange()" to setup the event.

Eliyahu

"william" <wi*****@discussions.microsoft.com> wrote in message
news:79**********************************@microsof t.com...
Hi,

I have a dropdownlist control and a few textbox on my web form. How can I
update those textbox content when user select item from dropdownlist

control?
I really want to do this on client side so that don't need back to server.
Thanks.

william


Nov 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Russ | last post by:
Hi, I have found myself wanting to use an HTMLSelect control instead of a DropDownList so that I can programatically set the item colours in the list (not possible with DropDownList due to...
33
by: Lee C. | last post by:
I'm finding this to be extremely difficult to set up. I understand that Access won't manage the primary key and the cascade updates for a table. Fine. I tried changing the PK type to number and...
2
by: Grey | last post by:
I have a dropdownlist control in ASP.NET form. But when I click on the control and attempt to change the option, there is nothing to happen to the server side, that is cannot trigger in action. How...
4
by: huzz | last post by:
I am trying to access a DropDownList control inside a repeater using ItemCommand as shown below but for some reason i can't access the DropDownList. When i step through the debug i get <undefine...
2
by: Luis Esteban Valencia | last post by:
Hello I have a datagrid with a dropdownlist that has the products, another column has the price of the product and when the user changes the product it also must change the price how can I achieve...
4
by: Matt Jensen | last post by:
Howdy all Been searching and can't find a good answer to my problem. I've got a usercontrol 'banner' at the top of my page, and when the selection in the dropdown list changes I want the "host"...
6
by: n33470 | last post by:
Hi all, We have a user control that contains a DropDownList. This user control appears on a web page. Suppose the name of the userControl on the web page is called "ucLookup". Suppose the...
2
by: Billy | last post by:
Change DataGrid EditControl On Data Value Hi, I have a datagrid, and on editing, I want to change the control in the third colunm based on the value of the first column. The value in the...
2
by: glenn | last post by:
Hi folks, I am trying to determine which item in a DropDownList Web control has been selected. I have posted an OnSelectedIndexChanged subroutine in my code with a reference to the subroutine...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.