示例#1
0
 private void dupliquerToolStripMenuItem_Click(object sender, EventArgs e)
 {
     Ecole schoolSelected = this.getEcole(lstToSchedule.SelectedItems[0].Name);
     p_isModified = true;
     frmItemCalendar frmNewRdV = new frmItemCalendar(schoolSelected, true);
     // frmNewRdV.SetEcole = schoolMove;
     frmNewRdV.Owner = this;
     frmNewRdV.Show();
 }
示例#2
0
        /// <summary>
        /// Evénement décloenché lors d'un Drag And Drop
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void objCalendar_DragDrop(object sender, System.Windows.Forms.DragEventArgs e)
        {
            if (e.Effect == DragDropEffects.Move)
            {
                Ecole schoolMove = (Ecole)e.Data.GetData(typeof(Ecole));
                
                Point clientPoint = objCalendar.PointToClient(new Point(e.X, e.Y));
                ICalendarSelectableElement ele;
                ele = objCalendar.HitTest(clientPoint, true);


                frmItemCalendar frmNewRdV = new frmItemCalendar(schoolMove, ele.Date);
               // frmNewRdV.SetEcole = schoolMove;
                frmNewRdV.Owner = this;
                frmNewRdV.Show();
            }

            //System.Windows.Forms.Calendar.Calendar calMove = (System.Windows.Forms.Calendar.Calendar)sender;

        }
示例#3
0
        /// <summary>
        /// Evénement déclenché lors d'un double clic sur un élément
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void objCalendar_ItemDoubleClick(object sender, System.Windows.Forms.Calendar.CalendarItemEventArgs e)
        {
            System.Windows.Forms.Calendar.Calendar calendarUp = (System.Windows.Forms.Calendar.Calendar)sender;
            IEnumerable<CalendarItem> schoolCollection = calendarUp.GetSelectedItems();

            Ecole ecoleItem = this.getEcole((string)(schoolCollection.ElementAt(0).Tag));
            frmItemCalendar frmNewRdV = new frmItemCalendar(ecoleItem);
            // frmNewRdV.SetEcole = schoolMove;
            frmNewRdV.Owner = this;
            frmNewRdV.Show();

        }
示例#4
0
 /// <summary>
 /// Evénement lorsqu'on double clic sur un Item
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void lstToSchedule_DoubleClick(object sender, System.EventArgs e)
 {
     ListView lb = (ListView)sender;
     Ecole schoolSelected = this.getEcole(lb.SelectedItems[0].Name);
     if (schoolSelected.isSchedule)
     {
         frmItemCalendar frmNewRdV = new frmItemCalendar(schoolSelected);
         // frmNewRdV.SetEcole = schoolMove;
         frmNewRdV.Owner = this;
         frmNewRdV.Show();
     }
 }