/// <summary>
        /// Initializes a new instance of the <see cref="ShowOperationsControl"/> class.
        /// </summary>
        public ShowOperationsControl()
        {
            InitializeComponent();
            listViewOperations.View = View.Details;
            listViewOperations.LabelEdit = false;
            listViewOperations.AllowColumnReorder = true;
            listViewOperations.FullRowSelect = true;

            // Create columns for the items and subitems.
            listViewOperations.Columns.Add("OID", 50);
            listViewOperations.Columns.Add("Date", 100);
            listViewOperations.Columns.Add("Team", 110);
            listViewOperations.Columns.Add("Process", 155);
            listViewOperations.Columns.Add("Diagnosis", 155);
            listViewOperations.Columns.Add("Performed", 155);
            listViewOperations.Columns.Add("Add. Info.", 100);
            listViewOperations.Columns.Add("Medication", 130);
            opControl = new OPControl(this.patComp);
            opControl.ButtonClearData.Visible = false;
            opControl.ButtonSaveOperation.Visible = false;
            opControl.ButtonToday.Visible = false;
            opControl.ButtonSaveAndPrint.Visible = false;

            opControl.TextBoxOPTeam.ReadOnly = true;
            opControl.TextBoxOPDate.ReadOnly = true;
            opControl.TextBoxOPDiagnoses.ReadOnly = true;
            opControl.TextBoxOPProcess.ReadOnly = true;
            opControl.TextBoxPerformedOP.ReadOnly = true;
            opControl.TextBoxAdditionalInformation.ReadOnly = true;
            opControl.TextBoxMedication.ReadOnly = true;
            opControl.TextBoxIntdiagnoses.ReadOnly = true;
            opControl.ComboBoxPPPS.Enabled = false;
            opControl.ComboBoxResult.Enabled = false;
            opControl.ComboBoxKathDays.Enabled = false;
            opControl.ComboBoxOrgan.Enabled = false;
            opControl.TextBoxOpResult.Enabled = false;
            opControl.Location = new Point(10, 220);
            this.Controls.Add(opControl);

            this.listBoxDays.Items.AddRange(new object[] {
            "12",
            "24",
            "36"});

            this.listBoxCopys.Items.AddRange(new object[] {
            "1",
            "2",
            "3"});

            this.listBoxDays.SelectedIndex = 0;
            this.listBoxCopys.SelectedIndex = 1;
        }
        private void OPWriterForm_Load(object sender, EventArgs e)
        {
            this.oPControl = new OPControl();
            this.oPControl.Enabled = true;
            this.oPControl.Location = new System.Drawing.Point(6, 55);
            this.oPControl.Name = "opControl";
            this.oPControl.ButtonSaveOperation.Text = "Export Operation";
            this.oPControl.ButtonSaveAndPrint.Text = "Export and Print OP";
            this.oPControl.LabelPatient.Hide();
            this.oPControl.hideForOpWriter();
            this.oPControl.Store += new NewOperationStoreEventHandler(oPControl_Store);
            try
            {
                this.labelDBInfo.Text = "DB Found: " + this.patComp.GetAllPatients().Count + " Patients";
            } catch (Exception) {
                this.labelDBInfo.Text = "No Db Found";
            }

            this.Controls.Add(this.oPControl);

            if (!string.IsNullOrEmpty(SPD.GUI.OPWriter.Properties.Settings.Default.exportPath)) {
                this.textBoxExportPath.Text = SPD.GUI.OPWriter.Properties.Settings.Default.exportPath;
            }
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="MainForm"/> class.
        /// </summary>
        public MainForm()
        {
            //this.tmrFade = new System.Timers.Timer();
            //((System.ComponentModel.ISupportInitialize)(this.tmrFade)).BeginInit();
            InitializeComponent();
            //((System.ComponentModel.ISupportInitialize)(this.tmrFade)).EndInit();

            ////Shows Dialog for BL selection
            //ServerSelectionForm serverSelectionForm = new ServerSelectionForm();
            //serverSelectionForm.TopMost = true;
            //serverSelectionForm.ShowDialog();
            ////Generate the Selected BusinessLogic
            //patComp = SPDLFactory.GetBussinessLogicObject(ServerSelectionForm.GetEndPointData());//new SPDBL();

            patComp = new SPDBL();

            this.newOperation = new OPControl(this.patComp);
            this.newOperation.Store += new NewOperationStoreEventHandler(newOperation_Store);
            this.newPatientControl = new NewPatientControl(this.patComp);
            this.newPatientControl.Store += new NewPatientStoreEventHandler(this.patientStore);
            this.patientSearchControl = new PatientSearchControl();
            this.patientSearchControl.AddVisit += new AddVisitEventHandler(patientSearchControl_AddVisit);
            this.patientSearchControl.ChangePatientData += new ChangePatientDataEventHandler(patientSearchControl_ChangePatientData);
            this.patientSearchControl.ShowPatientData += new ShowPatientDataEventHandler(patientSearchControl_ShowPatientData);
            this.patientSearchControl.ShowVisits += new ShowVisitsEventHandler(patientSearchControl_ShowVisits);
            this.patientSearchControl.AddOperation += new AddOperationEventHandler(patientSearchControl_AddOperation);
            this.patientSearchControl.AddFurtherTreatment += new AddFurtherTreatmentEventHandler(patientSearchControl_AddFurtherTreatment);
            this.patientSearchControl.ShowOperations += new ShowOperationsEventHandler(patientSearchControl_ShowOperations);
            this.patientSearchControl.AddImages += new ImagesEventHandler(patientSearchControl_AddImages);
            this.patientSearchControl.SelectionChange += new SelectionChangeEventHandler(patientSearchControl_SelectionChange);
            this.patientSearchControl.PlanOP += new PlanOPEventHandler(patientSearchControl_PlanOP);
            this.patientSearchControl.NextAction += new NextActionEventHandler(patientSearchControl_NextAction);
            this.imagesControl = new ImagesControl();
            this.imagesControl.Store += new PhotoStoreEventHandler(imagesControl_Store);
            this.imagesControl.Delete += new DeleteImageEventHandler(imagesControl_Delete);
            this.showOperationsControl = new ShowOperationsControl();
            this.showOperationsControl.ChangeOP += new ChangeOPEventHandler(showOperationsControl_ChangeOP);
            this.newVisit = new NewVisit(this.patComp);
            this.visitsControl = new VisitsControl();
            this.visitsControl.Change += new VisitChangeEventHandler(visitControl_VisitChange);
            this.newVisit.Store +=new NewVisitStoreEventHandler(this.visitStore);
            this.furtherTreatmentControl = new FinalReportControl();
            this.furtherTreatmentControl.Store += new NewFinalReportStoreEventHandler(furtherTreatmentControl_Store);
            this.printMorePatientsControl = new PrintMorePatientsControl();
            this.barDiagramm = new BarDiagram();
            this.backupForm = new BackupForm();
            this.nextActionControl = new NextActionControl(this.patComp);
            this.nextActionOverviewControl = new NextActionOverviewControl(this.patComp);
            this.importControl = new ImportControl(this.patComp);
            this.overviewControl = new OverviewControl(this.patComp);

            Bitmap img;
            img = SPD.GUI.Properties.Resources.logogross;

            PictureBox picBox = new PictureBox();
            picBox.Image = img;
            picBox.Size = new Size(591, 383);
            picBox.Location = new System.Drawing.Point(200, 10);
            this.Controls.Add(picBox);

            img = SPD.GUI.Properties.Resources.KinderurologieLogo;
            picBox = new PictureBox();
            picBox.Image = img;
            picBox.Size = new Size(482, 323);
            picBox.Location = new System.Drawing.Point(259, 435);
            this.Controls.Add(picBox);

            //
            // tmrFade
            //
            //this.tmrFade.Interval = 10;
            //this.tmrFade.SynchronizingObject = this;
            //this.tmrFade.Elapsed += new System.Timers.ElapsedEventHandler(this.tmrFade_Elapsed);

            //this.Opacity = 0;
            //this.Show();
            //tmrFade.Enabled = true;

            this.Text = Application.ProductName + " - " + Application.ProductVersion; // + " - Development Version!!";

            this.menuStrip.Items["backupToolStripMenuItem"].Enabled = patComp.SupportsBackup();
            ((ToolStripMenuItem)this.menuStrip.Items["settingsToolStripMenuItem"]).DropDownItems["databaseSettingsToolStripMenuItem"].Enabled = patComp.SupportDatabaseManagement();
        }