Solved

Data Binding

Posted on 1998-10-23
4
164 Views
Last Modified: 2013-12-25
How can I populate the dropdown list with the data retrieved from the database? How can I Populate another dropdown list within the same form depending on the selection made?
Please Explain Me in detail.
Dear Sybe you have given me some hint but i could not achieve it with database.Please Help Me out,I will be very thankfull to you.
0
Comment
Question by:vipin072998
  • 2
4 Comments
 
LVL 28

Expert Comment

by:sybe
ID: 1855940
First of all, did you get the javascript working that I posted ?. You did not comment it anymore, and the question is still locked by someone else. Anyway, I thought you'd lost interest in dealing with the issue.

If you understand how the javascript code works, then the next step is populate the javascript arrays from the database.

That is a next step, because you need a script to write a script :)

Explaining things in detail and without concrete example is hard. I think it would be much easier if you gave some details about the database you use, and what exactly you want to have in the dropdownboxes. That I could post some working code.

However, though the technique is known to me, it still takes a lot of time to write code for a specific goal. I must find some inspiration.

And lastly, if I would write a working code for you, without that you understand how it works, you might run into trouble if you want to change something.
That is why I ask you if you understand the javascript I posted before.


0
 

Author Comment

by:vipin072998
ID: 1855941
Thanks A lot .
I am using personal oracle as a backend and i hav created four tables named emp_mast proj-mast,comp_mast,act_mast .The Table emp_mast holds all the information pertaining to employees and proj_mast contains info regarding all the projects running within the organization.Every project has compoment associated with the project which is stored in comp_mast.Every particular component has some activity like coding,designing etc. so I want a system in which depending on the selected project which is retrieved from database only corresponding components should be retrieved and displayed within same form and upon selection of component the corresponding activity box should be populated.
Now i want to embed this particulat thing in a page which uses active server pages.I have searched thro' the entire VBScript book but I think arrays are still not implemented in VBScript and I am not able to mix the two VBSCRIPT and Javascript.
Is There any way I can extract Info from database using Javascript.I am also trying to get out of this problem,it takes hell of time.So Please help me out.
or It is possible using Visual Basic OCX(Acivex Control).
0
 

Author Comment

by:vipin072998
ID: 1855942
Thanks A lot .
I am using personal oracle as a backend and i hav created four tables named emp_mast proj-mast,comp_mast,act_mast .The Table emp_mast holds all the information pertaining to employees and proj_mast contains info regarding all the projects running within the organization.Every project has compoment associated with the project which is stored in comp_mast.Every particular component has some activity like coding,designing etc. so I want a system in which depending on the selected project which is retrieved from database only corresponding components should be retrieved and displayed within same form and upon selection of component the corresponding activity box should be populated.
Now i want to embed this particulat thing in a page which uses active server pages.I have searched thro' the entire VBScript book but I think arrays are still not implemented in VBScript and I am not able to mix the two VBSCRIPT and Javascript.
Is There any way I can extract Info from database using Javascript.I am also trying to get out of this problem,it takes hell of time.So Please help me out.
or It is possible using Visual Basic OCX(Acivex Control).
0
 
LVL 1

Accepted Solution

by:
rajgn earned 80 total points
ID: 1855943
Vipin:

You can use arrays in VB Script.The task you're looking for can be accomplished by using VB Script without mixing javascript(on server side). I suggest one way to do it. Use VB Script to extract data from database and populate the dropdown you want. Write client side javascript for onChange event of that dropdown. So, when user selects any item from that list, you can populate the another dropdown depending on it. Well, regarding storing the data retrieved from database as I said before, you can use arrays in VB Script. If you're not comfortable with them, I suggest you to use a Dictionary object(in asp). Hope this will solve your problem.
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Read about why website design really matters in today's demanding market.
FAQ pages provide a simple way for you to supply and for customers to find answers to the most common questions about your company. Here are six reasons why your company website should have a FAQ page
This tutorial demonstrates how to identify and create boundary or building outlines in Google Maps. In this example, I outline the boundaries of an enclosed skatepark within a community park.  Login to your Google Account, then  Google for "Google M…
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question