dear all
have a good day
i've a radschadualr in which students segister there schadual.
this schadual consists of substances each one is (leacture-tutorial-lab).
what i need is forcing the student to choose these sub categories (leacture-tutorial-lab) before leaving to choose new subject. and if he tries an error msg popup saying that "you should choose all substance groop- please complete your choice".
here is the code i wrote but it does't work.
if(this.treeView.SelectedNode == null)return;if (this.treeView.SelectedNode.Value != "m")return;string s = this.treeView.SelectedNode.Text;string corsnode = this.treeView.SelectedNode.ParentNode.Text;string cors_id = corsnode.Substring(0, corsnode.IndexOf('-') - 1).Trim();string stu_id = Session["test"].ToString();OracleConnection conn = new OracleConnection(ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString);try{conn.Open();OracleCommand cmd = new OracleCommand("COMPLETE_GROUP_TYPE");cmd.CommandType =CommandType.StoredProcedure;cmd.Connection = conn;cmd.Parameters.Add("COURSEID", OracleType.Char).Value = cors_id.ToString();cmd.Parameters.Add("STUDENTID", OracleType.Char).Value = stu_id.ToString();cmd.ExecuteNonQuery();}catch (Exception ex){Label2.Text ="ERROR."+ ex.Message;}finally{conn.Close();}