コード例 #1
0
ファイル: StructureCreate.aspx.cs プロジェクト: skrishnau/LMS
 void CustomDialog1_ItemClick(object sender, IdAndNameEventArgs e)
 {
     //copy the year and sub-years from the choosen program  to this program
     if (e.Id == 0)
     {
         CustomDialog1.CloseDialog();
         return;
     }
     using (var helper = new DbHelper.Structure())
     {
         var copied = helper.CopyYearsAndSubyears(e.Id, ParentId);
         if (copied)
         {
             Response.Redirect("~/Views/Structure/?edit=1");
         }
         else
         {
             lblCopyError.Visible = true;
             CustomDialog1.CloseDialog();
         }
     }
 }