diff --git a/Project/Properties/AssemblyInfo.cs b/Project/Properties/AssemblyInfo.cs index 9ee470d..7472ce5 100644 --- a/Project/Properties/AssemblyInfo.cs +++ b/Project/Properties/AssemblyInfo.cs @@ -32,5 +32,5 @@ using System.Runtime.InteropServices; // 모든 값을 지정하거나 아래와 같이 '*'를 사용하여 빌드 번호 및 수정 번호가 자동으로 // 지정되도록 할 수 있습니다. // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("22.01.17.1150")] -[assembly: AssemblyFileVersion("22.01.17.1150")] +[assembly: AssemblyVersion("22.01.18.2150")] +[assembly: AssemblyFileVersion("22.01.18.2150")] diff --git a/SubProject/FBS0000/FBS0000.csproj b/SubProject/FBS0000/FBS0000.csproj index 2477611..f407450 100644 --- a/SubProject/FBS0000/FBS0000.csproj +++ b/SubProject/FBS0000/FBS0000.csproj @@ -122,6 +122,12 @@ fLovWorkUser.cs + + Form + + + fImpKunTae.cs + Form @@ -170,6 +176,9 @@ fLovWorkUser.cs + + fImpKunTae.cs + fWorkTableUser.cs diff --git a/SubProject/FBS0000/Holiday/WorkTable.cs b/SubProject/FBS0000/Holiday/WorkTable.cs index 9ef7f68..71d4999 100644 --- a/SubProject/FBS0000/Holiday/WorkTable.cs +++ b/SubProject/FBS0000/Holiday/WorkTable.cs @@ -53,6 +53,10 @@ namespace FBS0000 var cols = new List(); cols.AddRange(new string[] { "분류", "사번", "직급", "성명" }); + var coltag = new List(); + var initdate = new DateTime(1982, 11, 23); + coltag.AddRange(new DateTime[] { initdate, initdate, initdate, initdate }); + var sd = DateTime.Parse(tbSD.Text); var ed = DateTime.Parse(tbED.Text); var idx = 0; ; @@ -60,14 +64,18 @@ namespace FBS0000 { var curDate = sd.AddDays(idx++); cols.Add(curDate.Day.ToString("00") + "\r\n" + curDate.DayOfWeek.ToString().Substring(0, 3)); + coltag.Add(curDate); + if (curDate.ToShortDateString() == ed.ToShortDateString()) break; } cols.AddRange(new string[] { "발생", "사용", "잔여" }); + coltag.AddRange(new DateTime[] { initdate, initdate, initdate }); //열제목 설정 fpSpread1_Sheet1.Columns.Count = cols.Count; for (int c = 0; c < cols.Count; c++) { + fpSpread1_Sheet1.Columns[c].Tag = coltag[c]; fpSpread1_Sheet1.Columns[c].Label = cols[c]; if (c < 4) fpSpread1_Sheet1.Columns[c].BackColor = Color.WhiteSmoke; else if (c > cols.Count - 4) fpSpread1_Sheet1.Columns[c].BackColor = Color.WhiteSmoke; @@ -82,7 +90,7 @@ namespace FBS0000 //해당 기간내의 사용 //var taUser = new dsMSSQLTableAdapters.EETGW_WorkTableUserTableAdapter(); - var dtUser = JobReport.OrderBy(t => t.userProcess+ t.name).GroupBy(t => t.id);// taUser.GetData(FCOMMON.info.Login.gcode, tbGrp.Text); + var dtUser = JobReport.OrderBy(t => t.userProcess + t.name).GroupBy(t => t.id);// taUser.GetData(FCOMMON.info.Login.gcode, tbGrp.Text); var users = new List(); var seq = 0; @@ -147,8 +155,11 @@ namespace FBS0000 } else { - fpSpread1_Sheet1.Cells[rowindex, c].Note = string.Empty; - fpSpread1_Sheet1.Cells[rowindex, c].BackColor = Color.FromArgb(240, 240, 240); ; + if (fpSpread1_Sheet1.Cells[rowindex, c].Tag == null) + { + fpSpread1_Sheet1.Cells[rowindex, c].Note = string.Empty; + //fpSpread1_Sheet1.Cells[rowindex, c].BackColor = Color.FromArgb(240, 240, 240); + } } //입사일이면 메세지 추가 @@ -170,15 +181,88 @@ namespace FBS0000 if (string.IsNullOrEmpty(dr.tag) == false) fpSpread1_Sheet1.Cells[rowindex, c].Value = dr.tag; else if (dr.term > 0) { - fpSpread1_Sheet1.Cells[rowindex, c].BackColor = Color.Lime; - fpSpread1_Sheet1.Cells[rowindex, c].Value = "Y"; + + + var timedays = dr.term;// Math.Floor(dr.CrTime / 8f); + var curday = 0; + var accday = 1; + while (accday <= timedays) + { + //var remaintime = dr.CrTime - accday * 8f; + var columnindex = c + curday; + var columnDate = (DateTime)this.fpSpread1_Sheet1.Columns[columnindex].Tag; + + + var drHolyChk = HolyList.Where(t => t.pdate == columnDate.ToShortDateString()).FirstOrDefault(); + var drholyOK = false; + if (drHolyChk != null && drHolyChk.free) drholyOK = true; //이러면 휴일이었다 + + if (drholyOK == false) + { + fpSpread1_Sheet1.Cells[rowindex, c + curday].Value = dr.cate.Substring(0, 2); + + if (dr.cate == "이월") + fpSpread1_Sheet1.Cells[rowindex, c + curday].BackColor = Color.Gold; + else if (dr.cate == "경조") + fpSpread1_Sheet1.Cells[rowindex, c + curday].BackColor = Color.Pink; + else + fpSpread1_Sheet1.Cells[rowindex, c + curday].BackColor = Color.Lime; + + fpSpread1_Sheet1.Cells[rowindex, c + curday].Tag = "1"; + accday += 1; + } + + curday += 1; + + } + + + + + //for (int ii = 0; ii < dr.term; ii++) + //{ + + // if (dr.cate == "이월") + // fpSpread1_Sheet1.Cells[rowindex, c + ii].BackColor = Color.Gold; + // else + // fpSpread1_Sheet1.Cells[rowindex, c + ii].BackColor = Color.Lime; + // fpSpread1_Sheet1.Cells[rowindex, c + ii].Value = dr.cate.Substring(0, 2); + // fpSpread1_Sheet1.Cells[rowindex, c + ii].Tag = "1"; + //} + } + else if (dr.term != 0) + { + fpSpread1_Sheet1.Cells[rowindex, c].Value = dr.term.ToString() + "Y"; } - else if (dr.term != 0) fpSpread1_Sheet1.Cells[rowindex, c].Value = dr.term.ToString() + "Y"; if (dr.CrTime != 0) { - fpSpread1_Sheet1.Cells[rowindex, c].Value = dr.CrTime.ToString(); - fpSpread1_Sheet1.Cells[rowindex, c].BackColor = Color.DeepSkyBlue; + var timedays = Math.Floor(dr.CrTime / 8f); + var curday = 0; + var accday = 1; + while (accday <= timedays) + { + var remaintime = dr.CrTime - ((accday-1) * 8f); + var columnindex = c + curday; + var columnDate = (DateTime)this.fpSpread1_Sheet1.Columns[columnindex].Tag; + + + var drHolyChk = HolyList.Where(t => t.pdate == columnDate.ToShortDateString()).FirstOrDefault(); + var drholyOK = false; + if (drHolyChk != null && drHolyChk.free) drholyOK = true; //이러면 휴일이었다 + + if (drholyOK == false) + { + if (remaintime > 8) remaintime = 8; + fpSpread1_Sheet1.Cells[rowindex, c + curday].Value = remaintime.ToString(); + fpSpread1_Sheet1.Cells[rowindex, c + curday].BackColor = Color.DeepSkyBlue; + fpSpread1_Sheet1.Cells[rowindex, c + curday].Tag = "1"; + accday += 1; + } + + curday += 1; + + } } if (string.IsNullOrEmpty(dr.contents) == false) fpSpread1_Sheet1.Cells[rowindex, c].Note += $"({dr.cate}){dr.contents}"; @@ -223,15 +307,16 @@ namespace FBS0000 else { //근무를 안했다 - fpSpread1_Sheet1.Cells[rowindex, c].Value = string.Empty; - fpSpread1_Sheet1.Cells[rowindex, c].BackColor = Color.White; - //fpSpread1_Sheet1.Cells[rowindex, c].Note = string.Empty; + var celltag = fpSpread1_Sheet1.Cells[rowindex, c].Tag; + if (celltag == null) //다른곳에서 지정했다면 처리하지 않는다. + { + fpSpread1_Sheet1.Cells[rowindex, c].Value = string.Empty; + fpSpread1_Sheet1.Cells[rowindex, c].BackColor = Color.White; + //fpSpread1_Sheet1.Cells[rowindex, c].Note = string.Empty; + } } } - } - - } var jan = jand - used; @@ -239,7 +324,6 @@ namespace FBS0000 fpSpread1_Sheet1.Cells[rowindex, c++].Value = used > 0 ? used.ToString() : string.Empty; fpSpread1_Sheet1.Cells[rowindex, c++].Value = jan > 0 ? jan.ToString() : string.Empty; - rowindex += 1; } @@ -364,7 +448,7 @@ namespace FBS0000 private void btXls_Click(object sender, EventArgs e) { - + SaveFileDialog sd = new SaveFileDialog(); diff --git a/SubProject/FBS0000/Holiday/fHolyday.Designer.cs b/SubProject/FBS0000/Holiday/fHolyday.Designer.cs index 18cd857..5148b7f 100644 --- a/SubProject/FBS0000/Holiday/fHolyday.Designer.cs +++ b/SubProject/FBS0000/Holiday/fHolyday.Designer.cs @@ -30,21 +30,21 @@ { this.components = new System.ComponentModel.Container(); System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(fHolyday)); - FarPoint.Win.Spread.CellType.TextCellType textCellType1 = new FarPoint.Win.Spread.CellType.TextCellType(); - FarPoint.Win.Spread.CellType.DateTimeCellType dateTimeCellType1 = new FarPoint.Win.Spread.CellType.DateTimeCellType(); - FarPoint.Win.Spread.CellType.TextCellType textCellType2 = new FarPoint.Win.Spread.CellType.TextCellType(); - FarPoint.Win.Spread.CellType.TextCellType textCellType3 = new FarPoint.Win.Spread.CellType.TextCellType(); - FarPoint.Win.Spread.CellType.TextCellType textCellType4 = new FarPoint.Win.Spread.CellType.TextCellType(); - FarPoint.Win.Spread.CellType.NumberCellType numberCellType1 = new FarPoint.Win.Spread.CellType.NumberCellType(); - FarPoint.Win.Spread.CellType.NumberCellType numberCellType2 = new FarPoint.Win.Spread.CellType.NumberCellType(); - FarPoint.Win.Spread.CellType.TextCellType textCellType5 = new FarPoint.Win.Spread.CellType.TextCellType(); - FarPoint.Win.Spread.CellType.TextCellType textCellType6 = new FarPoint.Win.Spread.CellType.TextCellType(); - FarPoint.Win.Spread.CellType.NumberCellType numberCellType3 = new FarPoint.Win.Spread.CellType.NumberCellType(); - FarPoint.Win.Spread.CellType.NumberCellType numberCellType4 = new FarPoint.Win.Spread.CellType.NumberCellType(); - FarPoint.Win.Spread.CellType.NumberCellType numberCellType5 = new FarPoint.Win.Spread.CellType.NumberCellType(); - FarPoint.Win.Spread.CellType.NumberCellType numberCellType6 = new FarPoint.Win.Spread.CellType.NumberCellType(); - FarPoint.Win.Spread.CellType.NumberCellType numberCellType7 = new FarPoint.Win.Spread.CellType.NumberCellType(); - FarPoint.Win.Spread.CellType.NumberCellType numberCellType8 = new FarPoint.Win.Spread.CellType.NumberCellType(); + FarPoint.Win.Spread.CellType.TextCellType textCellType7 = new FarPoint.Win.Spread.CellType.TextCellType(); + FarPoint.Win.Spread.CellType.DateTimeCellType dateTimeCellType2 = new FarPoint.Win.Spread.CellType.DateTimeCellType(); + FarPoint.Win.Spread.CellType.TextCellType textCellType8 = new FarPoint.Win.Spread.CellType.TextCellType(); + FarPoint.Win.Spread.CellType.TextCellType textCellType9 = new FarPoint.Win.Spread.CellType.TextCellType(); + FarPoint.Win.Spread.CellType.TextCellType textCellType10 = new FarPoint.Win.Spread.CellType.TextCellType(); + FarPoint.Win.Spread.CellType.NumberCellType numberCellType9 = new FarPoint.Win.Spread.CellType.NumberCellType(); + FarPoint.Win.Spread.CellType.NumberCellType numberCellType10 = new FarPoint.Win.Spread.CellType.NumberCellType(); + FarPoint.Win.Spread.CellType.TextCellType textCellType11 = new FarPoint.Win.Spread.CellType.TextCellType(); + FarPoint.Win.Spread.CellType.TextCellType textCellType12 = new FarPoint.Win.Spread.CellType.TextCellType(); + FarPoint.Win.Spread.CellType.NumberCellType numberCellType11 = new FarPoint.Win.Spread.CellType.NumberCellType(); + FarPoint.Win.Spread.CellType.NumberCellType numberCellType12 = new FarPoint.Win.Spread.CellType.NumberCellType(); + FarPoint.Win.Spread.CellType.NumberCellType numberCellType13 = new FarPoint.Win.Spread.CellType.NumberCellType(); + FarPoint.Win.Spread.CellType.NumberCellType numberCellType14 = new FarPoint.Win.Spread.CellType.NumberCellType(); + FarPoint.Win.Spread.CellType.NumberCellType numberCellType15 = new FarPoint.Win.Spread.CellType.NumberCellType(); + FarPoint.Win.Spread.CellType.NumberCellType numberCellType16 = new FarPoint.Win.Spread.CellType.NumberCellType(); this.bn = new System.Windows.Forms.BindingNavigator(this.components); this.bindingNavigatorCountItem = new System.Windows.Forms.ToolStripLabel(); this.bindingNavigatorMoveFirstItem = new System.Windows.Forms.ToolStripButton(); @@ -90,19 +90,20 @@ this.toolStripSeparator2 = new System.Windows.Forms.ToolStripSeparator(); this.복사ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.현재사원원장보기ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); + this.fpSpread1_Sheet1 = new FarPoint.Win.Spread.SheetView(); this.bs = new System.Windows.Forms.BindingSource(this.components); this.ta = new FBS0000.dsMSSQLTableAdapters.HolydayTableAdapter(); this.taUser = new FBS0000.dsMSSQLTableAdapters.EETGW_WorkTableUserTableAdapter(); this.textBox1 = new System.Windows.Forms.TextBox(); - this.fpSpread1_Sheet1 = new FarPoint.Win.Spread.SheetView(); + this.toolStripButton3 = new System.Windows.Forms.ToolStripButton(); ((System.ComponentModel.ISupportInitialize)(this.bn)).BeginInit(); this.bn.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.dsMSSQL)).BeginInit(); this.toolStrip1.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.fpSpread1)).BeginInit(); this.cmO.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.bs)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.fpSpread1_Sheet1)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.bs)).BeginInit(); this.SuspendLayout(); // // bn @@ -134,7 +135,8 @@ this.toolStripLabel8, this.sbJan, this.toolStripButton4, - this.toolStripButton5}); + this.toolStripButton5, + this.toolStripButton3}); this.bn.Location = new System.Drawing.Point(0, 822); this.bn.MoveFirstItem = this.bindingNavigatorMoveFirstItem; this.bn.MoveLastItem = this.bindingNavigatorMoveLastItem; @@ -180,6 +182,7 @@ // this.bindingNavigatorPositionItem.AccessibleName = "위치"; this.bindingNavigatorPositionItem.AutoSize = false; + this.bindingNavigatorPositionItem.Font = new System.Drawing.Font("맑은 고딕", 9F); this.bindingNavigatorPositionItem.Name = "bindingNavigatorPositionItem"; this.bindingNavigatorPositionItem.Size = new System.Drawing.Size(50, 23); this.bindingNavigatorPositionItem.Text = "0"; @@ -225,6 +228,7 @@ // // toolStripButton2 // + this.toolStripButton2.Enabled = false; this.toolStripButton2.Image = ((System.Drawing.Image)(resources.GetObject("toolStripButton2.Image"))); this.toolStripButton2.ImageTransparentColor = System.Drawing.Color.Magenta; this.toolStripButton2.Name = "toolStripButton2"; @@ -354,6 +358,7 @@ // tbSD // this.tbSD.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.tbSD.Font = new System.Drawing.Font("맑은 고딕", 9F); this.tbSD.Name = "tbSD"; this.tbSD.Size = new System.Drawing.Size(100, 31); this.tbSD.TextBoxTextAlign = System.Windows.Forms.HorizontalAlignment.Center; @@ -368,6 +373,7 @@ // tbED // this.tbED.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.tbED.Font = new System.Drawing.Font("맑은 고딕", 9F); this.tbED.Name = "tbED"; this.tbED.Size = new System.Drawing.Size(100, 31); this.tbED.TextBoxTextAlign = System.Windows.Forms.HorizontalAlignment.Center; @@ -436,7 +442,7 @@ this.fpSpread1.CellClick += new FarPoint.Win.Spread.CellClickEventHandler(this.fpSpread1_CellClick); this.fpSpread1.KeyDown += new System.Windows.Forms.KeyEventHandler(this.fpSpread1_KeyDown); this.fpSpread1.SetViewportLeftColumn(0, 0, 1); - this.fpSpread1.SetActiveViewport(0, 0, -1); + this.fpSpread1.SetActiveViewport(0, -1, -1); // // cmO // @@ -512,29 +518,6 @@ this.현재사원원장보기ToolStripMenuItem.Text = "현재 사원 원장 보기"; this.현재사원원장보기ToolStripMenuItem.Click += new System.EventHandler(this.현재사원원장보기ToolStripMenuItem_Click); // - // bs - // - this.bs.DataMember = "Holyday"; - this.bs.DataSource = this.dsMSSQL; - this.bs.Sort = ""; - // - // ta - // - this.ta.ClearBeforeFill = true; - // - // taUser - // - this.taUser.ClearBeforeFill = true; - // - // textBox1 - // - this.textBox1.Dock = System.Windows.Forms.DockStyle.Bottom; - this.textBox1.Location = new System.Drawing.Point(0, 801); - this.textBox1.Name = "textBox1"; - this.textBox1.Size = new System.Drawing.Size(1465, 21); - this.textBox1.TabIndex = 5; - this.textBox1.KeyDown += new System.Windows.Forms.KeyEventHandler(this.textBox1_KeyDown); - // // fpSpread1_Sheet1 // this.fpSpread1_Sheet1.Reset(); @@ -561,27 +544,27 @@ this.fpSpread1_Sheet1.ColumnHeader.Cells.Get(0, 13).Value = "전일(일)"; this.fpSpread1_Sheet1.ColumnHeader.Cells.Get(0, 14).Value = "전일(H)"; this.fpSpread1_Sheet1.ColumnHeader.Rows.Get(0).Height = 31F; - this.fpSpread1_Sheet1.Columns.Get(0).CellType = textCellType1; + this.fpSpread1_Sheet1.Columns.Get(0).CellType = textCellType7; this.fpSpread1_Sheet1.Columns.Get(0).DataField = "cate"; this.fpSpread1_Sheet1.Columns.Get(0).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(0).Label = "구분"; this.fpSpread1_Sheet1.Columns.Get(0).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center; - dateTimeCellType1.Calendar = new System.Globalization.GregorianCalendar(System.Globalization.GregorianCalendarTypes.Localized); - dateTimeCellType1.CalendarSurroundingDaysColor = System.Drawing.SystemColors.GrayText; - dateTimeCellType1.MaximumTime = System.TimeSpan.Parse("23:59:59.9999999"); - dateTimeCellType1.TimeDefault = new System.DateTime(2022, 1, 14, 10, 18, 20, 842); - this.fpSpread1_Sheet1.Columns.Get(1).CellType = dateTimeCellType1; + dateTimeCellType2.Calendar = new System.Globalization.GregorianCalendar(System.Globalization.GregorianCalendarTypes.Localized); + dateTimeCellType2.CalendarSurroundingDaysColor = System.Drawing.SystemColors.GrayText; + dateTimeCellType2.MaximumTime = System.TimeSpan.Parse("23:59:59.9999999"); + dateTimeCellType2.TimeDefault = new System.DateTime(2022, 1, 18, 21, 13, 14, 988); + this.fpSpread1_Sheet1.Columns.Get(1).CellType = dateTimeCellType2; this.fpSpread1_Sheet1.Columns.Get(1).DataField = "sdate"; this.fpSpread1_Sheet1.Columns.Get(1).Label = "시작일"; this.fpSpread1_Sheet1.Columns.Get(1).Tag = "pdate"; this.fpSpread1_Sheet1.Columns.Get(1).Width = 71F; - this.fpSpread1_Sheet1.Columns.Get(2).CellType = textCellType2; + this.fpSpread1_Sheet1.Columns.Get(2).CellType = textCellType8; this.fpSpread1_Sheet1.Columns.Get(2).Formula = "CHOOSE(WEEKDAY(RC[-1]),\"일\",\"월\",\"화\",\"수\",\"목\",\"금\",\"토\")"; this.fpSpread1_Sheet1.Columns.Get(2).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(2).Label = "요일"; this.fpSpread1_Sheet1.Columns.Get(2).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(3).BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(192))))); - this.fpSpread1_Sheet1.Columns.Get(3).CellType = textCellType3; + this.fpSpread1_Sheet1.Columns.Get(3).CellType = textCellType9; this.fpSpread1_Sheet1.Columns.Get(3).DataField = "uid"; this.fpSpread1_Sheet1.Columns.Get(3).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(3).Label = "사번"; @@ -589,98 +572,98 @@ this.fpSpread1_Sheet1.Columns.Get(3).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(3).Width = 151F; this.fpSpread1_Sheet1.Columns.Get(4).BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224))))); - textCellType4.ReadOnly = true; - this.fpSpread1_Sheet1.Columns.Get(4).CellType = textCellType4; + textCellType10.ReadOnly = true; + this.fpSpread1_Sheet1.Columns.Get(4).CellType = textCellType10; this.fpSpread1_Sheet1.Columns.Get(4).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(4).Label = "성명"; this.fpSpread1_Sheet1.Columns.Get(4).Tag = "name"; this.fpSpread1_Sheet1.Columns.Get(4).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(4).Width = 151F; this.fpSpread1_Sheet1.Columns.Get(5).BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(224)))), ((int)(((byte)(192))))); - numberCellType1.MaximumValue = 999999999999999D; - numberCellType1.MinimumValue = -999999999999999D; - this.fpSpread1_Sheet1.Columns.Get(5).CellType = numberCellType1; + numberCellType9.MaximumValue = 999999999999999D; + numberCellType9.MinimumValue = -999999999999999D; + this.fpSpread1_Sheet1.Columns.Get(5).CellType = numberCellType9; this.fpSpread1_Sheet1.Columns.Get(5).DataField = "term"; this.fpSpread1_Sheet1.Columns.Get(5).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(5).Label = "사용(일)"; this.fpSpread1_Sheet1.Columns.Get(5).Tag = "dr"; this.fpSpread1_Sheet1.Columns.Get(5).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(6).BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(224)))), ((int)(((byte)(192))))); - numberCellType2.MaximumValue = 999999999999999D; - numberCellType2.MinimumValue = -999999999999999D; - this.fpSpread1_Sheet1.Columns.Get(6).CellType = numberCellType2; + numberCellType10.MaximumValue = 999999999999999D; + numberCellType10.MinimumValue = -999999999999999D; + this.fpSpread1_Sheet1.Columns.Get(6).CellType = numberCellType10; this.fpSpread1_Sheet1.Columns.Get(6).DataField = "CrTime"; this.fpSpread1_Sheet1.Columns.Get(6).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(6).Label = "사용(H)"; this.fpSpread1_Sheet1.Columns.Get(6).Tag = "drh"; this.fpSpread1_Sheet1.Columns.Get(6).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center; - this.fpSpread1_Sheet1.Columns.Get(7).CellType = textCellType5; + this.fpSpread1_Sheet1.Columns.Get(7).CellType = textCellType11; this.fpSpread1_Sheet1.Columns.Get(7).DataField = "contents"; this.fpSpread1_Sheet1.Columns.Get(7).Label = "내용"; this.fpSpread1_Sheet1.Columns.Get(7).Width = 151F; - this.fpSpread1_Sheet1.Columns.Get(8).CellType = textCellType6; + this.fpSpread1_Sheet1.Columns.Get(8).CellType = textCellType12; this.fpSpread1_Sheet1.Columns.Get(8).DataField = "tag"; this.fpSpread1_Sheet1.Columns.Get(8).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(8).Label = "#"; this.fpSpread1_Sheet1.Columns.Get(8).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(8).Width = 40F; this.fpSpread1_Sheet1.Columns.Get(9).BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(255))))); - numberCellType3.MaximumValue = 999999999999999D; - numberCellType3.MinimumValue = -999999999999999D; - this.fpSpread1_Sheet1.Columns.Get(9).CellType = numberCellType3; + numberCellType11.MaximumValue = 999999999999999D; + numberCellType11.MinimumValue = -999999999999999D; + this.fpSpread1_Sheet1.Columns.Get(9).CellType = numberCellType11; this.fpSpread1_Sheet1.Columns.Get(9).DataField = "termDr"; this.fpSpread1_Sheet1.Columns.Get(9).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(9).Label = "발생(일)"; this.fpSpread1_Sheet1.Columns.Get(9).Tag = "cr"; this.fpSpread1_Sheet1.Columns.Get(9).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(10).BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(255))))); - numberCellType4.MaximumValue = 999999999999999D; - numberCellType4.MinimumValue = -999999999999999D; - this.fpSpread1_Sheet1.Columns.Get(10).CellType = numberCellType4; + numberCellType12.MaximumValue = 999999999999999D; + numberCellType12.MinimumValue = -999999999999999D; + this.fpSpread1_Sheet1.Columns.Get(10).CellType = numberCellType12; this.fpSpread1_Sheet1.Columns.Get(10).DataField = "DrTime"; this.fpSpread1_Sheet1.Columns.Get(10).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(10).Label = "발생(H)"; this.fpSpread1_Sheet1.Columns.Get(10).Tag = "crh"; this.fpSpread1_Sheet1.Columns.Get(10).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(11).BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224))))); - numberCellType5.DecimalPlaces = 1; - numberCellType5.MaximumValue = 999999999999999D; - numberCellType5.MinimumValue = -999999999999999D; - numberCellType5.ReadOnly = true; - this.fpSpread1_Sheet1.Columns.Get(11).CellType = numberCellType5; + numberCellType13.DecimalPlaces = 1; + numberCellType13.MaximumValue = 999999999999999D; + numberCellType13.MinimumValue = -999999999999999D; + numberCellType13.ReadOnly = true; + this.fpSpread1_Sheet1.Columns.Get(11).CellType = numberCellType13; this.fpSpread1_Sheet1.Columns.Get(11).Formula = "RC[2]+RC[-2]-RC[-6]"; this.fpSpread1_Sheet1.Columns.Get(11).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(11).Label = "잔량(일)"; this.fpSpread1_Sheet1.Columns.Get(11).Tag = "jand"; this.fpSpread1_Sheet1.Columns.Get(11).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(12).BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224))))); - numberCellType6.DecimalPlaces = 2; - numberCellType6.MaximumValue = 999999999999999D; - numberCellType6.MinimumValue = -999999999999999D; - numberCellType6.ReadOnly = true; - this.fpSpread1_Sheet1.Columns.Get(12).CellType = numberCellType6; + numberCellType14.DecimalPlaces = 2; + numberCellType14.MaximumValue = 999999999999999D; + numberCellType14.MinimumValue = -999999999999999D; + numberCellType14.ReadOnly = true; + this.fpSpread1_Sheet1.Columns.Get(12).CellType = numberCellType14; this.fpSpread1_Sheet1.Columns.Get(12).Formula = "RC[2]+RC[-2]-RC[-6]"; this.fpSpread1_Sheet1.Columns.Get(12).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(12).Label = "잔량(H)"; this.fpSpread1_Sheet1.Columns.Get(12).Tag = "janh"; this.fpSpread1_Sheet1.Columns.Get(12).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(13).BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(224)))), ((int)(((byte)(192))))); - numberCellType7.DecimalPlaces = 1; - numberCellType7.MaximumValue = 999999999999999D; - numberCellType7.MinimumValue = -999999999999999D; - numberCellType7.ReadOnly = true; - this.fpSpread1_Sheet1.Columns.Get(13).CellType = numberCellType7; + numberCellType15.DecimalPlaces = 1; + numberCellType15.MaximumValue = 999999999999999D; + numberCellType15.MinimumValue = -999999999999999D; + numberCellType15.ReadOnly = true; + this.fpSpread1_Sheet1.Columns.Get(13).CellType = numberCellType15; this.fpSpread1_Sheet1.Columns.Get(13).ForeColor = System.Drawing.Color.Gray; this.fpSpread1_Sheet1.Columns.Get(13).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(13).Label = "전일(일)"; this.fpSpread1_Sheet1.Columns.Get(13).Tag = "yjand"; this.fpSpread1_Sheet1.Columns.Get(13).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(14).BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(224)))), ((int)(((byte)(192))))); - numberCellType8.DecimalPlaces = 2; - numberCellType8.MaximumValue = 999999999999999D; - numberCellType8.MinimumValue = -999999999999999D; - numberCellType8.ReadOnly = true; - this.fpSpread1_Sheet1.Columns.Get(14).CellType = numberCellType8; + numberCellType16.DecimalPlaces = 2; + numberCellType16.MaximumValue = 999999999999999D; + numberCellType16.MinimumValue = -999999999999999D; + numberCellType16.ReadOnly = true; + this.fpSpread1_Sheet1.Columns.Get(14).CellType = numberCellType16; this.fpSpread1_Sheet1.Columns.Get(14).ForeColor = System.Drawing.Color.Gray; this.fpSpread1_Sheet1.Columns.Get(14).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center; this.fpSpread1_Sheet1.Columns.Get(14).Label = "전일(H)"; @@ -695,6 +678,39 @@ this.fpSpread1_Sheet1.ShowRowSelector = true; this.fpSpread1_Sheet1.ReferenceStyle = FarPoint.Win.Spread.Model.ReferenceStyle.A1; // + // bs + // + this.bs.DataMember = "Holyday"; + this.bs.DataSource = this.dsMSSQL; + this.bs.Sort = ""; + // + // ta + // + this.ta.ClearBeforeFill = true; + // + // taUser + // + this.taUser.ClearBeforeFill = true; + // + // textBox1 + // + this.textBox1.Dock = System.Windows.Forms.DockStyle.Bottom; + this.textBox1.Location = new System.Drawing.Point(0, 801); + this.textBox1.Name = "textBox1"; + this.textBox1.Size = new System.Drawing.Size(1465, 21); + this.textBox1.TabIndex = 5; + this.textBox1.KeyDown += new System.Windows.Forms.KeyEventHandler(this.textBox1_KeyDown); + // + // toolStripButton3 + // + this.toolStripButton3.Alignment = System.Windows.Forms.ToolStripItemAlignment.Right; + this.toolStripButton3.Image = ((System.Drawing.Image)(resources.GetObject("toolStripButton3.Image"))); + this.toolStripButton3.ImageTransparentColor = System.Drawing.Color.Magenta; + this.toolStripButton3.Name = "toolStripButton3"; + this.toolStripButton3.Size = new System.Drawing.Size(79, 24); + this.toolStripButton3.Text = "붙여넣기"; + this.toolStripButton3.Click += new System.EventHandler(this.toolStripButton3_Click_1); + // // fHolyday // this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F); @@ -716,8 +732,8 @@ this.toolStrip1.PerformLayout(); ((System.ComponentModel.ISupportInitialize)(this.fpSpread1)).EndInit(); this.cmO.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.bs)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.fpSpread1_Sheet1)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.bs)).EndInit(); this.ResumeLayout(false); this.PerformLayout(); @@ -775,5 +791,6 @@ private System.Windows.Forms.TextBox textBox1; private System.Windows.Forms.ToolStripMenuItem 복사ToolStripMenuItem; private FarPoint.Win.Spread.SheetView fpSpread1_Sheet1; + private System.Windows.Forms.ToolStripButton toolStripButton3; } } \ No newline at end of file diff --git a/SubProject/FBS0000/Holiday/fHolyday.cs b/SubProject/FBS0000/Holiday/fHolyday.cs index 72bc6a9..a9fb298 100644 --- a/SubProject/FBS0000/Holiday/fHolyday.cs +++ b/SubProject/FBS0000/Holiday/fHolyday.cs @@ -90,9 +90,11 @@ namespace FBS0000 btAdd.Enabled = true; 복사ToolStripMenuItem.Enabled = true; toolStripButton2.Enabled = true; + toolStripButton3.Enabled = true; } else { + toolStripButton3.Enabled = false; toolStripButton2.Enabled = false; btSave.Enabled = false; btDel.Enabled = false; @@ -626,5 +628,11 @@ namespace FBS0000 } + + private void toolStripButton3_Click_1(object sender, EventArgs e) + { + var f = new FBS0000.Holiday.fImpKunTae(); + f.ShowDialog(); + } } } diff --git a/SubProject/FBS0000/Holiday/fHolyday.resx b/SubProject/FBS0000/Holiday/fHolyday.resx index 59436f2..820cdaf 100644 --- a/SubProject/FBS0000/Holiday/fHolyday.resx +++ b/SubProject/FBS0000/Holiday/fHolyday.resx @@ -214,35 +214,50 @@ iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8 - YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAJ6SURBVDhPjZNbSF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ir7UJtZfftyATqeT+8o2D8JSjQrAJblrncYL7ZJ2+bfaFnC/1S1NjL3diRat7qrO7wLRP3HjWsojBeCo + mDEo5mNjuweFGvjWg2EBhCbpkW78htSHHwRyNdmgAFzPEee2iFkzayy2OLXzT4gr6UdUnlXrullsxxQ+ + kx0g8BTA3aZlButjSTyjODq/WcQcW/B/Je4OQhLvKQDnzN1mp0nnkvAhR8VuMzNrpm1mpjgkoVwB/v8D + TgDQASA1MVpwzwAAAABJRU5ErkJggg== @@ -269,6 +284,22 @@ 659, 17 + + 737, 17 + + + + AAEAAAD/////AQAAAAAAAAAEAQAAACZTeXN0ZW0uR2xvYmFsaXphdGlvbi5HcmVnb3JpYW5DYWxlbmRh + cgYAAAAGbV90eXBlEW1fY3VycmVudEVyYVZhbHVlD3R3b0RpZ2l0WWVhck1heBpDYWxlbmRhcittX2N1 + cnJlbnRFcmFWYWx1ZRVDYWxlbmRhcittX2lzUmVhZE9ubHkYQ2FsZW5kYXIrdHdvRGlnaXRZZWFyTWF4 + AwAAAAAAK1N5c3RlbS5HbG9iYWxpemF0aW9uLkdyZWdvcmlhbkNhbGVuZGFyVHlwZXMICAgBCAT+//// + K1N5c3RlbS5HbG9iYWxpemF0aW9uLkdyZWdvcmlhbkNhbGVuZGFyVHlwZXMBAAAAB3ZhbHVlX18ACAEA + AAD/////AQgAAP////8AAQgAAAs= + + + + 294, 17 + R0lGODlhEAAQAIQfAJXG2JXa+ZLO5ChrlkCy4TZ1kiVvpCN0trvo9SN5xTd4lrfh7iR9zo3S+EGz7JDJ @@ -308,22 +339,6 @@ vmv/Akgg2IMBDgsSdJwcAEICDhoECjDAmQIFBQouXNiwQYPOgqgLBgQAOw== - - 737, 17 - - - - AAEAAAD/////AQAAAAAAAAAEAQAAACZTeXN0ZW0uR2xvYmFsaXphdGlvbi5HcmVnb3JpYW5DYWxlbmRh - cgYAAAAGbV90eXBlEW1fY3VycmVudEVyYVZhbHVlD3R3b0RpZ2l0WWVhck1heBpDYWxlbmRhcittX2N1 - cnJlbnRFcmFWYWx1ZRVDYWxlbmRhcittX2lzUmVhZE9ubHkYQ2FsZW5kYXIrdHdvRGlnaXRZZWFyTWF4 - AwAAAAAAK1N5c3RlbS5HbG9iYWxpemF0aW9uLkdyZWdvcmlhbkNhbGVuZGFyVHlwZXMICAgBCAT+//// - K1N5c3RlbS5HbG9iYWxpemF0aW9uLkdyZWdvcmlhbkNhbGVuZGFyVHlwZXMBAAAAB3ZhbHVlX18ACAEA - AAD/////AQgAAP////8AAQgAAAs= - - - - 294, 17 - 358, 17 diff --git a/SubProject/FBS0000/Holiday/fHolyday_Add.Designer.cs b/SubProject/FBS0000/Holiday/fHolyday_Add.Designer.cs index db308c8..a965fd0 100644 --- a/SubProject/FBS0000/Holiday/fHolyday_Add.Designer.cs +++ b/SubProject/FBS0000/Holiday/fHolyday_Add.Designer.cs @@ -48,7 +48,6 @@ this.cmbType = new System.Windows.Forms.ComboBox(); this.nudDrHour = new System.Windows.Forms.NumericUpDown(); this.nudDrDay = new System.Windows.Forms.NumericUpDown(); - this.dateTimePicker2 = new System.Windows.Forms.DateTimePicker(); sdateLabel = new System.Windows.Forms.Label(); contentsLabel = new System.Windows.Forms.Label(); uidLabel = new System.Windows.Forms.Label(); @@ -114,6 +113,36 @@ label2.TabIndex = 14; label2.Text = "사용시간"; // + // label3 + // + label3.AutoSize = true; + label3.Location = new System.Drawing.Point(279, 307); + label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); + label3.Name = "label3"; + label3.Size = new System.Drawing.Size(65, 19); + label3.TabIndex = 10; + label3.Text = "발생시간"; + // + // label4 + // + label4.AutoSize = true; + label4.Location = new System.Drawing.Point(28, 307); + label4.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); + label4.Name = "label4"; + label4.Size = new System.Drawing.Size(51, 19); + label4.TabIndex = 8; + label4.Text = "발생일"; + // + // label5 + // + label5.AutoSize = true; + label5.Location = new System.Drawing.Point(44, 81); + label5.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); + label5.Name = "label5"; + label5.Size = new System.Drawing.Size(37, 19); + label5.TabIndex = 4; + label5.Text = "구분"; + // // dsMSSQL // this.dsMSSQL.DataSetName = "dsMSSQL"; @@ -220,16 +249,6 @@ this.nudDrHour.TabIndex = 11; this.nudDrHour.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; // - // label3 - // - label3.AutoSize = true; - label3.Location = new System.Drawing.Point(279, 307); - label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); - label3.Name = "label3"; - label3.Size = new System.Drawing.Size(65, 19); - label3.TabIndex = 10; - label3.Text = "발생시간"; - // // nudDrDay // this.nudDrDay.DecimalPlaces = 2; @@ -244,41 +263,12 @@ this.nudDrDay.TabIndex = 9; this.nudDrDay.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; // - // label4 - // - label4.AutoSize = true; - label4.Location = new System.Drawing.Point(28, 307); - label4.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); - label4.Name = "label4"; - label4.Size = new System.Drawing.Size(51, 19); - label4.TabIndex = 8; - label4.Text = "발생일"; - // - // label5 - // - label5.AutoSize = true; - label5.Location = new System.Drawing.Point(44, 81); - label5.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); - label5.Name = "label5"; - label5.Size = new System.Drawing.Size(37, 19); - label5.TabIndex = 4; - label5.Text = "구분"; - // - // dateTimePicker2 - // - this.dateTimePicker2.Location = new System.Drawing.Point(12, 176); - this.dateTimePicker2.Name = "dateTimePicker2"; - this.dateTimePicker2.Size = new System.Drawing.Size(252, 27); - this.dateTimePicker2.TabIndex = 18; - this.dateTimePicker2.Visible = false; - // // fHolyday_Add // this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 19F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.ClientSize = new System.Drawing.Size(566, 430); this.Controls.Add(this.contentsTextBox); - this.Controls.Add(this.dateTimePicker2); this.Controls.Add(this.nudDrHour); this.Controls.Add(label3); this.Controls.Add(this.nudDrDay); @@ -327,6 +317,5 @@ private System.Windows.Forms.ComboBox cmbType; private System.Windows.Forms.NumericUpDown nudDrHour; private System.Windows.Forms.NumericUpDown nudDrDay; - private System.Windows.Forms.DateTimePicker dateTimePicker2; } } \ No newline at end of file diff --git a/SubProject/FBS0000/Holiday/fHolyday_Add.cs b/SubProject/FBS0000/Holiday/fHolyday_Add.cs index 32f876f..66666ea 100644 --- a/SubProject/FBS0000/Holiday/fHolyday_Add.cs +++ b/SubProject/FBS0000/Holiday/fHolyday_Add.cs @@ -60,7 +60,7 @@ namespace FBS0000 { cmbUser.SelectedValue = dr.uid;// FCOMMON.info.Login.no;// .Text = FCOMMON.info.Login.nameK + "(" + FCOMMON.info.Login.no + ")"; dateTimePicker1.Value = dr.sdate; - dateTimePicker2.Value = dr.edate; + //dateTimePicker2.Value = dr.edate; cmbType.Text = dr.cate; contentsTextBox.Text = dr.contents; @@ -73,6 +73,10 @@ namespace FBS0000 bInit = true; + if (this.WindowState == FormWindowState.Minimized) this.WindowState = FormWindowState.Normal; + if (this.RestoreBounds.X + this.RestoreBounds.Width < 300 && this.RestoreBounds.X < 0) + this.Location = new Point(0, 0); + } private void btOK_Click(object sender, EventArgs e) @@ -99,7 +103,8 @@ namespace FBS0000 dr.uid = userid;// cmbType.SelectedValue.ToString(); dr.sdate = dateTimePicker1.Value; - dr.edate = dateTimePicker2.Value; + dr.edate = dr.sdate; + // dr.edate = dateTimePicker2.Value; dr.cate = cmbType.Text; dr.contents = contentsTextBox.Text; @@ -121,8 +126,8 @@ namespace FBS0000 if (!bInit) return; - if(dateTimePicker1.Value > this.dateTimePicker2.Value) - this.dateTimePicker2.Value = dateTimePicker1.Value; + //if(dateTimePicker1.Value > this.dateTimePicker2.Value) + // this.dateTimePicker2.Value = dateTimePicker1.Value; RefreshTerm(); diff --git a/SubProject/FBS0000/Holiday/fHolyday_Add.resx b/SubProject/FBS0000/Holiday/fHolyday_Add.resx index ac8fe14..25994aa 100644 --- a/SubProject/FBS0000/Holiday/fHolyday_Add.resx +++ b/SubProject/FBS0000/Holiday/fHolyday_Add.resx @@ -132,15 +132,6 @@ False - - 17, 17 - - - 186, 17 - - - 248, 17 - False @@ -150,4 +141,13 @@ False + + 17, 17 + + + 186, 17 + + + 248, 17 + \ No newline at end of file diff --git a/SubProject/FBS0000/Holiday/fImpKunTae.Designer.cs b/SubProject/FBS0000/Holiday/fImpKunTae.Designer.cs new file mode 100644 index 0000000..01f6a8c --- /dev/null +++ b/SubProject/FBS0000/Holiday/fImpKunTae.Designer.cs @@ -0,0 +1,175 @@ + +namespace FBS0000.Holiday +{ + partial class fImpKunTae + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.label1 = new System.Windows.Forms.Label(); + this.listView1 = new System.Windows.Forms.ListView(); + this.columnHeader1 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader())); + this.columnHeader2 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader())); + this.columnHeader3 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader())); + this.columnHeader4 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader())); + this.button1 = new System.Windows.Forms.Button(); + this.button2 = new System.Windows.Forms.Button(); + this.columnHeader5 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader())); + this.columnHeader6 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader())); + this.columnHeader7 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader())); + this.progressBar1 = new System.Windows.Forms.ProgressBar(); + this.SuspendLayout(); + // + // label1 + // + this.label1.AutoSize = true; + this.label1.Font = new System.Drawing.Font("굴림", 13F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129))); + this.label1.Location = new System.Drawing.Point(22, 21); + this.label1.Name = "label1"; + this.label1.Size = new System.Drawing.Size(548, 54); + this.label1.TabIndex = 0; + this.label1.Text = "* 데이터양식 *\r\n\r\n해당 내용을 클립보드에 복사한 후 아래 붙여 넣기 버튼을 누르세요"; + // + // listView1 + // + this.listView1.CheckBoxes = true; + this.listView1.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] { + this.columnHeader7, + this.columnHeader1, + this.columnHeader2, + this.columnHeader3, + this.columnHeader4, + this.columnHeader5, + this.columnHeader6}); + this.listView1.FullRowSelect = true; + this.listView1.GridLines = true; + this.listView1.HideSelection = false; + this.listView1.Location = new System.Drawing.Point(25, 98); + this.listView1.Name = "listView1"; + this.listView1.Size = new System.Drawing.Size(703, 423); + this.listView1.TabIndex = 1; + this.listView1.UseCompatibleStateImageBehavior = false; + this.listView1.View = System.Windows.Forms.View.Details; + // + // columnHeader1 + // + this.columnHeader1.Text = "사번"; + this.columnHeader1.Width = 150; + // + // columnHeader2 + // + this.columnHeader2.Text = "종류"; + this.columnHeader2.Width = 100; + // + // columnHeader3 + // + this.columnHeader3.Text = "발생일"; + this.columnHeader3.Width = 80; + // + // columnHeader4 + // + this.columnHeader4.Text = "사용일"; + this.columnHeader4.Width = 80; + // + // button1 + // + this.button1.Location = new System.Drawing.Point(241, 532); + this.button1.Name = "button1"; + this.button1.Size = new System.Drawing.Size(487, 59); + this.button1.TabIndex = 2; + this.button1.Text = "저장"; + this.button1.UseVisualStyleBackColor = true; + this.button1.Click += new System.EventHandler(this.button1_Click); + // + // button2 + // + this.button2.Location = new System.Drawing.Point(25, 532); + this.button2.Name = "button2"; + this.button2.Size = new System.Drawing.Size(210, 59); + this.button2.TabIndex = 3; + this.button2.Text = "붙여넣기"; + this.button2.UseVisualStyleBackColor = true; + this.button2.Click += new System.EventHandler(this.button2_Click); + // + // columnHeader5 + // + this.columnHeader5.Text = "발생(H)"; + this.columnHeader5.Width = 80; + // + // columnHeader6 + // + this.columnHeader6.Text = "사용(H)"; + this.columnHeader6.Width = 80; + // + // columnHeader7 + // + this.columnHeader7.Text = "등록일"; + this.columnHeader7.Width = 120; + // + // progressBar1 + // + this.progressBar1.Dock = System.Windows.Forms.DockStyle.Bottom; + this.progressBar1.Location = new System.Drawing.Point(0, 599); + this.progressBar1.Name = "progressBar1"; + this.progressBar1.Size = new System.Drawing.Size(752, 23); + this.progressBar1.TabIndex = 4; + // + // fImpKunTae + // + this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.ClientSize = new System.Drawing.Size(752, 622); + this.Controls.Add(this.progressBar1); + this.Controls.Add(this.button2); + this.Controls.Add(this.button1); + this.Controls.Add(this.listView1); + this.Controls.Add(this.label1); + this.MaximizeBox = false; + this.MinimizeBox = false; + this.Name = "fImpKunTae"; + this.Text = "fImpKunTae"; + this.Load += new System.EventHandler(this.fImpKunTae_Load); + this.ResumeLayout(false); + this.PerformLayout(); + + } + + #endregion + + private System.Windows.Forms.Label label1; + private System.Windows.Forms.ListView listView1; + private System.Windows.Forms.ColumnHeader columnHeader1; + private System.Windows.Forms.ColumnHeader columnHeader2; + private System.Windows.Forms.ColumnHeader columnHeader3; + private System.Windows.Forms.ColumnHeader columnHeader4; + private System.Windows.Forms.Button button1; + private System.Windows.Forms.Button button2; + private System.Windows.Forms.ColumnHeader columnHeader7; + private System.Windows.Forms.ColumnHeader columnHeader5; + private System.Windows.Forms.ColumnHeader columnHeader6; + private System.Windows.Forms.ProgressBar progressBar1; + } +} \ No newline at end of file diff --git a/SubProject/FBS0000/Holiday/fImpKunTae.cs b/SubProject/FBS0000/Holiday/fImpKunTae.cs new file mode 100644 index 0000000..5353b09 --- /dev/null +++ b/SubProject/FBS0000/Holiday/fImpKunTae.cs @@ -0,0 +1,109 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace FBS0000.Holiday +{ + public partial class fImpKunTae : FCOMMON.fBase + { + public fImpKunTae() + { + InitializeComponent(); + } + + private void fImpKunTae_Load(object sender, EventArgs e) + { + + } + + private void button2_Click(object sender, EventArgs e) + { + if (Clipboard.ContainsText() == false) + { + FCOMMON.Util.MsgE("텍스트 자료가 없습니다"); + return; + } + + if (this.listView1.Items.Count > 0) + { + if (FCOMMON.Util.MsgQ("현재 내용을 삭제할까요?") == DialogResult.Yes) + { + this.listView1.Items.Clear(); + } + } + + listView1.SuspendLayout(); + var lines = Clipboard.GetText().Replace("\r", "").Split('\n'); + foreach (var line in lines) + { + var buffer = line.Split('\t'); + if (buffer.Length < 4) continue; + + var vdate = buffer[0].Trim(); + if (DateTime.TryParse(vdate, out DateTime val_date) == false) continue; + + var vno = buffer[1].Trim(); + if (string.IsNullOrEmpty(vno)) continue; + + var vcate = buffer[2].Trim(); + if (string.IsNullOrEmpty(vcate)) continue; + + var drday = buffer[3].Trim(); + if (float.TryParse(drday, out float val_drday) == false) continue; + + string drtime = "0"; + if (buffer.Length > 4) drtime = buffer[4].Trim(); + float.TryParse(drtime, out float val_drtime); + + string crday = "0"; + if (buffer.Length > 5) crday = buffer[5].Trim(); + float.TryParse(crday, out float val_crday); + + string crtime = "0"; + if (buffer.Length > 6) crtime = buffer[6].Trim(); + float.TryParse(crtime, out float val_crtime); + + var lv = this.listView1.Items.Add(val_date.ToShortDateString()); + lv.SubItems.Add(vno); + lv.SubItems.Add(vcate); + lv.SubItems.Add(drday.ToString()); + lv.SubItems.Add(drtime.ToString()); + lv.SubItems.Add(crday.ToString()); + lv.SubItems.Add(crtime.ToString()); + lv.Checked = true; + + } + listView1.ResumeLayout(); + } + + private void button1_Click(object sender, EventArgs e) + { + var items = this.listView1.CheckedItems; + if (items.Count < 1) + { + FCOMMON.Util.MsgE("선택된 아이템이 없습니다"); + return; + } + + if (FCOMMON.Util.MsgQ($"{items.Count} 건의 자료를 입력할까요?") != DialogResult.Yes) return; + + this.progressBar1.Maximum = items.Count; + this.progressBar1.Value = 0; + var ta = new dsMSSQLTableAdapters.HolydayTableAdapter(); + foreach (ListViewItem item in items) + { + ta.InsertShort(item.SubItems[2].Text, item.SubItems[0].Text, double.Parse(item.SubItems[4].Text), + "PASTE", "PASTE", item.SubItems[1].Text, FCOMMON.info.Login.no, DateTime.Now, + double.Parse(item.SubItems[3].Text), FCOMMON.info.Login.gcode, + double.Parse(item.SubItems[5].Text), double.Parse(item.SubItems[6].Text), "CLIPBOARD"); + this.progressBar1.Value += 1; + } + } + } +} diff --git a/SubProject/FBS0000/Holiday/fImpKunTae.resx b/SubProject/FBS0000/Holiday/fImpKunTae.resx new file mode 100644 index 0000000..29dcb1b --- /dev/null +++ b/SubProject/FBS0000/Holiday/fImpKunTae.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/SubProject/FBS0000/dsMSSQL.Designer.cs b/SubProject/FBS0000/dsMSSQL.Designer.cs index 7f99a28..619c5ae 100644 --- a/SubProject/FBS0000/dsMSSQL.Designer.cs +++ b/SubProject/FBS0000/dsMSSQL.Designer.cs @@ -8077,7 +8077,7 @@ SELECT idx, cate, result, sdate, edate, term, title, contents, uid, tolist, mail [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")] private void InitCommandCollection() { - this._commandCollection = new global::System.Data.SqlClient.SqlCommand[4]; + this._commandCollection = new global::System.Data.SqlClient.SqlCommand[5]; this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand(); this._commandCollection[0].Connection = this.Connection; this._commandCollection[0].CommandText = @"SELECT idx, cate, result, sdate, edate, term, title, contents, uid, tolist, mail, mailsend, reason, wuid, wdate, termDr, gcode, DrTime, CrTime, dbo.getUserName(uid) AS UserName, tag @@ -8121,6 +8121,26 @@ ORDER BY Holyday.sdate, Holyday.edate, Holyday.uid"; this._commandCollection[3].CommandType = global::System.Data.CommandType.Text; this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@gcode", global::System.Data.SqlDbType.VarChar, 10, global::System.Data.ParameterDirection.Input, 0, 0, "gcode", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idx", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "idx", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4] = new global::System.Data.SqlClient.SqlCommand(); + this._commandCollection[4].Connection = this.Connection; + this._commandCollection[4].CommandText = @"INSERT INTO Holyday + (cate, sdate, term, title, contents, uid, wuid, wdate, termDr, gcode, DrTime, CrTime, tag) +VALUES (@cate,@sdate,@term,@title,@contents,@uid,@wuid,@wdate,@termDr,@gcode,@DrTime,@CrTime,@tag); +SELECT idx, cate, result, sdate, edate, term, title, contents, uid, tolist, mail, mailsend, reason, wuid, wdate, termDr, gcode, DrTime, CrTime, dbo.getUserName(uid) AS UserName, tag FROM Holyday WHERE (idx = SCOPE_IDENTITY()) ORDER BY sdate, edate, uid"; + this._commandCollection[4].CommandType = global::System.Data.CommandType.Text; + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@cate", global::System.Data.SqlDbType.VarChar, 20, global::System.Data.ParameterDirection.Input, 0, 0, "cate", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@sdate", global::System.Data.SqlDbType.Date, 3, global::System.Data.ParameterDirection.Input, 0, 0, "sdate", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@term", global::System.Data.SqlDbType.Float, 8, global::System.Data.ParameterDirection.Input, 0, 0, "term", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@title", global::System.Data.SqlDbType.NVarChar, 255, global::System.Data.ParameterDirection.Input, 0, 0, "title", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@contents", global::System.Data.SqlDbType.NVarChar, 2147483647, global::System.Data.ParameterDirection.Input, 0, 0, "contents", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@uid", global::System.Data.SqlDbType.VarChar, 20, global::System.Data.ParameterDirection.Input, 0, 0, "uid", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@wuid", global::System.Data.SqlDbType.VarChar, 20, global::System.Data.ParameterDirection.Input, 0, 0, "wuid", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@wdate", global::System.Data.SqlDbType.SmallDateTime, 4, global::System.Data.ParameterDirection.Input, 0, 0, "wdate", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@termDr", global::System.Data.SqlDbType.Float, 8, global::System.Data.ParameterDirection.Input, 0, 0, "termDr", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@gcode", global::System.Data.SqlDbType.VarChar, 10, global::System.Data.ParameterDirection.Input, 0, 0, "gcode", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@DrTime", global::System.Data.SqlDbType.Float, 8, global::System.Data.ParameterDirection.Input, 0, 0, "DrTime", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CrTime", global::System.Data.SqlDbType.Float, 8, global::System.Data.ParameterDirection.Input, 0, 0, "CrTime", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@tag", global::System.Data.SqlDbType.VarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, "tag", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] @@ -8850,6 +8870,102 @@ ORDER BY Holyday.sdate, Holyday.edate, Holyday.uid"; } } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")] + [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] + [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, false)] + public virtual int InsertShort(string cate, string sdate, global::System.Nullable term, string title, string contents, string uid, string wuid, System.DateTime wdate, global::System.Nullable termDr, string gcode, global::System.Nullable DrTime, global::System.Nullable CrTime, string tag) { + global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[4]; + if ((cate == null)) { + command.Parameters[0].Value = global::System.DBNull.Value; + } + else { + command.Parameters[0].Value = ((string)(cate)); + } + if ((sdate == null)) { + command.Parameters[1].Value = global::System.DBNull.Value; + } + else { + command.Parameters[1].Value = ((string)(sdate)); + } + if ((term.HasValue == true)) { + command.Parameters[2].Value = ((double)(term.Value)); + } + else { + command.Parameters[2].Value = global::System.DBNull.Value; + } + if ((title == null)) { + command.Parameters[3].Value = global::System.DBNull.Value; + } + else { + command.Parameters[3].Value = ((string)(title)); + } + if ((contents == null)) { + command.Parameters[4].Value = global::System.DBNull.Value; + } + else { + command.Parameters[4].Value = ((string)(contents)); + } + if ((uid == null)) { + command.Parameters[5].Value = global::System.DBNull.Value; + } + else { + command.Parameters[5].Value = ((string)(uid)); + } + if ((wuid == null)) { + throw new global::System.ArgumentNullException("wuid"); + } + else { + command.Parameters[6].Value = ((string)(wuid)); + } + command.Parameters[7].Value = ((System.DateTime)(wdate)); + if ((termDr.HasValue == true)) { + command.Parameters[8].Value = ((double)(termDr.Value)); + } + else { + command.Parameters[8].Value = global::System.DBNull.Value; + } + if ((gcode == null)) { + throw new global::System.ArgumentNullException("gcode"); + } + else { + command.Parameters[9].Value = ((string)(gcode)); + } + if ((DrTime.HasValue == true)) { + command.Parameters[10].Value = ((double)(DrTime.Value)); + } + else { + command.Parameters[10].Value = global::System.DBNull.Value; + } + if ((CrTime.HasValue == true)) { + command.Parameters[11].Value = ((double)(CrTime.Value)); + } + else { + command.Parameters[11].Value = global::System.DBNull.Value; + } + if ((tag == null)) { + command.Parameters[12].Value = global::System.DBNull.Value; + } + else { + command.Parameters[12].Value = ((string)(tag)); + } + global::System.Data.ConnectionState previousConnectionState = command.Connection.State; + if (((command.Connection.State & global::System.Data.ConnectionState.Open) + != global::System.Data.ConnectionState.Open)) { + command.Connection.Open(); + } + int returnValue; + try { + returnValue = command.ExecuteNonQuery(); + } + finally { + if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) { + command.Connection.Close(); + } + } + return returnValue; + } } /// diff --git a/SubProject/FBS0000/dsMSSQL.xsd b/SubProject/FBS0000/dsMSSQL.xsd index 0a3f94b..f49d592 100644 --- a/SubProject/FBS0000/dsMSSQL.xsd +++ b/SubProject/FBS0000/dsMSSQL.xsd @@ -428,6 +428,31 @@ WHERE (gcode = @gcode) AND (idx = @idx) + + + + INSERT INTO Holyday + (cate, sdate, term, title, contents, uid, wuid, wdate, termDr, gcode, DrTime, CrTime, tag) +VALUES (@cate,@sdate,@term,@title,@contents,@uid,@wuid,@wdate,@termDr,@gcode,@DrTime,@CrTime,@tag); +SELECT idx, cate, result, sdate, edate, term, title, contents, uid, tolist, mail, mailsend, reason, wuid, wdate, termDr, gcode, DrTime, CrTime, dbo.getUserName(uid) AS UserName, tag FROM Holyday WHERE (idx = SCOPE_IDENTITY()) ORDER BY sdate, edate, uid + + + + + + + + + + + + + + + + + + @@ -799,7 +824,7 @@ WHERE (gcode = @gcode) AND (uid = @uid) AND (CONVERT(CHAR(10), sdate, 23) >= - + @@ -859,7 +884,7 @@ WHERE (gcode = @gcode) AND (uid = @uid) AND (CONVERT(CHAR(10), sdate, 23) >= - + @@ -911,7 +936,7 @@ WHERE (gcode = @gcode) AND (uid = @uid) AND (CONVERT(CHAR(10), sdate, 23) >= - + @@ -1004,7 +1029,7 @@ WHERE (gcode = @gcode) AND (uid = @uid) AND (CONVERT(CHAR(10), sdate, 23) >= - + @@ -1049,7 +1074,7 @@ WHERE (gcode = @gcode) AND (uid = @uid) AND (CONVERT(CHAR(10), sdate, 23) >= - + @@ -1062,7 +1087,7 @@ WHERE (gcode = @gcode) AND (uid = @uid) AND (CONVERT(CHAR(10), sdate, 23) >= - + @@ -1127,7 +1152,7 @@ WHERE (gcode = @gcode) AND (uid = @uid) AND (CONVERT(CHAR(10), sdate, 23) >= - + @@ -1265,19 +1290,19 @@ WHERE (gcode = @gcode) AND (uid = @uid) AND (CONVERT(CHAR(10), sdate, 23) >= - + - + - - + + diff --git a/SubProject/FBS0000/dsMSSQL.xss b/SubProject/FBS0000/dsMSSQL.xss index 26eed1d..1e295f3 100644 --- a/SubProject/FBS0000/dsMSSQL.xss +++ b/SubProject/FBS0000/dsMSSQL.xss @@ -8,13 +8,13 @@ - + - + \ No newline at end of file diff --git a/SubProject/FCOMMON/fBase.cs b/SubProject/FCOMMON/fBase.cs index c7cad87..44431b1 100644 --- a/SubProject/FCOMMON/fBase.cs +++ b/SubProject/FCOMMON/fBase.cs @@ -43,6 +43,10 @@ namespace FCOMMON FCOMMON.Util.SetFormStatus(ref form, this.Name, true); } + + if (this.WindowState == FormWindowState.Minimized) this.WindowState = FormWindowState.Normal; + if (this.RestoreBounds.X + this.RestoreBounds.Width < 300 && this.RestoreBounds.X < 0) + this.Location = new Point(0, 0); } } }