473,396 Members | 1,784 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,396 software developers and data experts.

populate dropdown list

Hi,can anyone help me?

I want to refresh 1 textbox value based on selected data in dropdown list.

both of them are from different tables.

Table A(dropdown list)
----------------------
ID Name
123 abc

Table B(text box)
-------------------
ID expenses
123 RM456

when i select the ID from dropdown list(Table A),I want the RM456 display in textbox.

can anyone have any suggestion?

best regards,
beekien
Dec 1 '11 #1
2 1648
jhardman
3,406 Expert 2GB
in order to do this seamlessly, you will need to use some javascript or ajax. Remember that asp runs on the server, not the browser, so when the user makes a selection there is no obvious way for the server to know and execute any code. Does this suggest anything to you?

Jared
Dec 2 '11 #2
@jhardman
Hi Jared,

thank you for your suggestion. I tried with xmlhttprequest to call another page. However, the 2nd pages failed to get the value that user's selection in 1st page.

do i use wrongly?

Regards,
bee kien
Dec 5 '11 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Dmitry Korolyov [MVP] | last post by:
Is that possible? In other words, I want a dropdown list (and other list-type controls) which appears in edit more of a templated column to be populated with data at the run time. An attempt to do so...
4
by: anonymous | last post by:
Hi Folks, I have a form with two Dropdown list boxes, which get loaded with data from Database. DropDownList1 gets data from Table1 and DropDownList2 gets data from Table2 Table1 has a...
1
by: Mark Goldin | last post by:
How can I populate a dropdownlist with data from a database using Microsoft.ApplicationBlocks.Data ? Thanks
3
by: Merdaad | last post by:
I saw an example of this which talked about assigning valueTextField and DataTextField. So I have twenty items coming back from the database(I use a dataadapter), do I need to go thru a loop to...
3
by: JIM.H. | last post by:
Hello, I am suing SELECT * from MyTable in a stored procedure and populate dropdown list. By using followings: ddlSP.DataSource = DS; ddlSP.DataTextField = "PName"; ddlSP.DataValueField = "PID";...
1
by: Johhn | last post by:
I am using VS 2005 and MS ACCESS database, i need to populate dropdown list box eith Items from row 1 to n and from x to y Any code samples? I am usig VB language. Thanks. Who gives me a...
3
by: er1 | last post by:
Hi all, I have created a double dropdown list. Based on the first list selection, second list populates (this works fine). I have a submit button, which when clicked should run a select query...
11
by: eureka | last post by:
Hi All, I'm training in Servlets, JSP and JavaScript, I have a web page in which there's a "StudentName" textbox and below it is a "Names" Dropdown list. Initially the Textbox is empty and...
1
by: fran7 | last post by:
Hi, Anyone know how to populate a dropdown list with data from database. I have an interface that generates the following code for names in my database. ..asp <%If Trim(rsCard("Author"))<>""...
0
TonFrere
by: TonFrere | last post by:
Hello, I'm building a windows form application in Visual C# using VS 2005. On my form I need to populate a combobox with Invoices# linked to the current reccord's Order# value. This means that: -...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

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.