Hi i want to read xml..
i have two combo boxes one is showing Prgorrames Name and 2nd will show Semester No with respected to Programme..
For example if I select Programme BBa so another combobox will show all the semesters of BBa...and when i select semester 5 so data of BBA 5 semester must be show in datagrid..
i m doing but i m not able to do it..
thats my code
private void Form2_Load(object sender, EventArgs e)
{
ds = new DataSet();
ds.ReadXml("D:\\student.xml");
for (int i = 0; i < ds.Tables[0].Rows.Count; i++ )
{
string n = ds.Tables[0].Rows[i].ItemArray[3].ToString();
cbProgramme.Items.Add(n);
}
}
private void cbSelect_SelectedIndexChanged(object sender, EventArgs e)
{
dv = new DataView();
for (int i = 0; i < ds.Tables[0].Rows.Count; i++ )
{
string n2 = ds.Tables[0].Rows[i].ItemArray[0].ToString();
cbSemNo.Items.Add(cbProgramme.Items[3]);
}
}
hope some one will solve it..
Regards...
Farhad