private void Student_Brief2_Load(object sender, EventArgs e)
        {
            this.decDetailBase = new UDTDetailContentBase.SingleUDCDecorator<UDT.StudentBrief2>(this, "StudentID",false);
            this.decDetailBase.AfterDataLoaded += new SingleUDCDecorator<UDT.StudentBrief2>.UDTDetailContentEventHandler(decDetailBase_AfterDataLoaded);
            this.decDetailBase.OnValidatingData += new SingleUDCDecorator<UDT.StudentBrief2>.UDTDetailContentEventHandler(decDetailBase_OnValidatingData);
            this.decDetailBase.OnReadDataError += new SingleUDCDecorator<UDT.StudentBrief2>.UDTDetailContentErrorEventHandler(decDetailBase_OnReadDataError);
            this.decDetailBase.OnSaveDataError += new SingleUDCDecorator<UDT.StudentBrief2>.UDTDetailContentErrorEventHandler(decDetailBase_OnSaveDataError);
            this.decDetailBase.AfterDataSaved += new EventHandler(decDetailBase_AfterDataSaved);

            WatchChange(new TextBoxSource(this.txtGraduateSemester));
            WatchChange(new TextBoxSource(this.txtGraduateYear));
            //WatchChange(new TextBoxSource(this.txtEmail));

            //log
            this.logAgent = new Log.LogAgent();
        }
        private void Student_Remark_Load(object sender, EventArgs e)
        {
            this.decDetailBase = new UDTDetailContentBase.SingleUDCDecorator<UDT.StudentRemark>(this, "StudentID");
            this.decDetailBase.AfterDataLoaded += new SingleUDCDecorator<UDT.StudentRemark>.UDTDetailContentEventHandler(decDetailBase_AfterDataLoaded);
            this.decDetailBase.OnValidatingData += new SingleUDCDecorator<UDT.StudentRemark>.UDTDetailContentEventHandler(decDetailBase_OnValidatingData);
            this.decDetailBase.OnReadDataError += new SingleUDCDecorator<UDT.StudentRemark>.UDTDetailContentErrorEventHandler(decDetailBase_OnReadDataError);
            this.decDetailBase.OnSaveDataError += new SingleUDCDecorator<UDT.StudentRemark>.UDTDetailContentErrorEventHandler(decDetailBase_OnSaveDataError);
            this.decDetailBase.OnSaveActionCanceled += new EventHandler(decDetailBase_OnSaveActionCanceled);
            this.decDetailBase.AfterDataSaved += new EventHandler(decDetailBase_AfterDataSaved);

            WatchChange(new TextBoxSource(txtRemark));
        }
        private void MyDetailContent_Load(object sender, EventArgs e)
        {
            this.decDetailBase = new UDTDetailContentBase.SingleUDCDecorator<MyUDT>(this, "StudentID");
            this.decDetailBase.AfterDataLoaded += new SingleUDCDecorator<MyUDT>.UDTDetailContentEventHandler(decDetailBase_OnBindingData);
            this.decDetailBase.OnValidatingData += new SingleUDCDecorator<MyUDT>.UDTDetailContentEventHandler(decDetailBase_OnValidatingData);
            this.decDetailBase.OnReadDataError += new SingleUDCDecorator<MyUDT>.UDTDetailContentErrorEventHandler(decDetailBase_OnReadDataError);
            this.decDetailBase.OnSaveDataError += new SingleUDCDecorator<MyUDT>.UDTDetailContentErrorEventHandler(decDetailBase_OnSaveDataError);
            this.decDetailBase.OnSaveActionCanceled += new EventHandler(decDetailBase_OnSaveActionCanceled);
            this.decDetailBase.AfterDataSaved += new EventHandler(decDetailBase_AfterDataSaved);

            this.radioButton1.CheckedChanged    +=new EventHandler(this.decDetailBase.something_changed);
        }
        private void Student_Email_Load(object sender, EventArgs e)
        {
            this.decDetailBase = new UDTDetailContentBase.SingleUDCDecorator<UDT.StudentBrief2>(this, "StudentID", false);
            this.decDetailBase.AfterDataLoaded += new SingleUDCDecorator<UDT.StudentBrief2>.UDTDetailContentEventHandler(decDetailBase_AfterDataLoaded);
            this.decDetailBase.OnValidatingData += new SingleUDCDecorator<UDT.StudentBrief2>.UDTDetailContentEventHandler(decDetailBase_OnValidatingData);
            this.decDetailBase.OnReadDataError += new SingleUDCDecorator<UDT.StudentBrief2>.UDTDetailContentErrorEventHandler(decDetailBase_OnReadDataError);
            this.decDetailBase.OnSaveDataError += new SingleUDCDecorator<UDT.StudentBrief2>.UDTDetailContentErrorEventHandler(decDetailBase_OnSaveDataError);
            this.decDetailBase.AfterDataSaved += new EventHandler(decDetailBase_AfterDataSaved);

            WatchChange(new TextBoxSource(this.txtEmail));

            //this.balloonTip1.SetBalloonCaption(this.btnDuplicate, "!");
            this.balloonTip1.SetBalloonText(this.btnDuplicate, "將此學生所有的 Email 複製到剪貼簿!");
            // this.balloonTip1.CaptionImage = global::WindowsApplication2.Properties.Resources.Warning;
            //this.balloonTip1.ShowBalloon(this.btnDuplicate);

            //log
            this.logAgent = new Log.LogAgent();
        }