Click here to Skip to main content
15,914,016 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I wanted to know how can I combine tables in one database. What I have is that all the tables have an INST_ID and within my program I am calling different things. I have a couple of drop down list that are data bound and the value is the INST_ID. I am trying to get one drop down list, (when selected), that has a name in it to populate the other drop down lists that are on the form. For Example:

If I select a name from the main drop down list the other drop down list will populate with years. Then the drop down lists that have years, once a year is selected, will populate the text boxes that I have lined up. Can someone show me a way of doing this?

C#
using System;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
using System.Drawing;
using System.Text;
using System.Data;
using System.Collections.Generic;
using System.Linq;
using System.Data.SqlClient;
using System.Configuration;
using System.Drawing.Printing;
public partial class SchoolReports : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }
    protected void DropDownListSchools_SelectedIndexChanged(object sender, EventArgs e)
    {
        SqlConnection con = new SqlConnection(System.Configuration.ConfigurationManager.ConnectionStrings["PassConnectionString"].ConnectionString);
        con.Open(); 
    }
    protected void DropDownListCFY1_SelectedIndexChanged(object sender, EventArgs e)
    {

    }
    protected void DropDownListCFY2_SelectedIndexChanged(object sender, EventArgs e)
    {

    }
    protected void DropDownListCFY3_SelectedIndexChanged(object sender, EventArgs e)
    {

    }
    protected void DropDownListCFY4_SelectedIndexChanged(object sender, EventArgs e)
    {

    }
    protected void DropDownListCFY5_SelectedIndexChanged(object sender, EventArgs e)
    {

    }
    protected void DropDownListFY1_SelectedIndexChanged(object sender, EventArgs e)
    {

    }
    protected void DropDownListFY2_SelectedIndexChanged(object sender, EventArgs e)
    {

    }
    protected void DropDownListFY3_SelectedIndexChanged(object sender, EventArgs e)
    {

    }
    protected void DropDownListFY4_SelectedIndexChanged(object sender, EventArgs e)
    {

    }
    protected void DropDownListFY5_SelectedIndexChanged(object sender, EventArgs e)
    {

    }
}
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900