开发测试文档麻醉系统修改1009-1

This commit is contained in:
leomo 2022-10-10 23:22:20 +08:00
parent feba69d35d
commit f23914306d
117 changed files with 7803 additions and 1046 deletions

View File

@ -54,10 +54,6 @@
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\..\..\Program Files (x86)\DotNetBar for Windows Forms\DevComponents.DotNetBar2.dll</HintPath>
</Reference>
<Reference Include="GoldPrinter, Version=2.5.5009.37801, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>Extensions\GoldPrinter.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Office.Interop.Excel, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c">
<SpecificVersion>False</SpecificVersion>
<EmbedInteropTypes>True</EmbedInteropTypes>
@ -79,6 +75,11 @@
<SpecificVersion>False</SpecificVersion>
<HintPath>Extensions\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="office, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<EmbedInteropTypes>True</EmbedInteropTypes>
<HintPath>..\..\AIMS演示版本\AIMS\Extensions\office.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Windows.Forms.DataVisualization" />
@ -1311,6 +1312,15 @@
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
<None Include="Template\手术清点记录单.xlsx">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</None>
<None Include="Template\排班按月.xlt">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</None>
<None Include="Template\职工出缺勤表.xlt">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</None>
</ItemGroup>
<ItemGroup>
<Content Include="aims.ico" />
@ -1328,7 +1338,6 @@
<Content Include="Extensions\DevComponents.DotNetBar.Schedule.dll" />
<Content Include="Extensions\DevComponents.DotNetBar.SuperGrid.dll" />
<Content Include="Extensions\DevComponents.DotNetBar2.dll" />
<Content Include="Extensions\GoldPrinter.dll" />
<Content Include="Extensions\Microsoft.Office.Interop.Excel.dll" />
<Content Include="Extensions\Microsoft.ReportViewer.Common.dll" />
<Content Include="Extensions\Microsoft.ReportViewer.ProcessingObjectModel.dll" />

Binary file not shown.

View File

@ -34,12 +34,12 @@
this.toolStripSeparator1 = new System.Windows.Forms.ToolStripSeparator();
this.tsbOperationReview = new System.Windows.Forms.ToolStripButton();
this.toolStripSeparator4 = new System.Windows.Forms.ToolStripSeparator();
this.tsbOperationRecover = new System.Windows.Forms.ToolStripButton();
this.toolStripSeparator3 = new System.Windows.Forms.ToolStripSeparator();
this.tspBAGD = new System.Windows.Forms.ToolStripButton();
this.toolStripSeparator6 = new System.Windows.Forms.ToolStripSeparator();
this.toolStripButton1 = new System.Windows.Forms.ToolStripButton();
this.toolStripSeparator5 = new System.Windows.Forms.ToolStripSeparator();
this.tsbOperationRecover = new System.Windows.Forms.ToolStripButton();
this.toolStripSeparator3 = new System.Windows.Forms.ToolStripSeparator();
this.tsbExit = new System.Windows.Forms.ToolStripButton();
this.toolStripSeparator2 = new System.Windows.Forms.ToolStripSeparator();
this.tsbSet = new System.Windows.Forms.ToolStripButton();
@ -171,12 +171,14 @@
this.tsbEditApply.Size = new System.Drawing.Size(68, 48);
this.tsbEditApply.Text = " 修改申请";
this.tsbEditApply.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
this.tsbEditApply.Visible = false;
this.tsbEditApply.Click += new System.EventHandler(this.tsbEditApply_Click);
//
// toolStripSeparator1
//
this.toolStripSeparator1.Name = "toolStripSeparator1";
this.toolStripSeparator1.Size = new System.Drawing.Size(6, 51);
this.toolStripSeparator1.Visible = false;
//
// tsbOperationReview
//
@ -187,12 +189,32 @@
this.tsbOperationReview.Size = new System.Drawing.Size(68, 48);
this.tsbOperationReview.Text = " 回顾手术";
this.tsbOperationReview.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
this.tsbOperationReview.Visible = false;
this.tsbOperationReview.Click += new System.EventHandler(this.tsbOperationReview_Click);
//
// toolStripSeparator4
//
this.toolStripSeparator4.Name = "toolStripSeparator4";
this.toolStripSeparator4.Size = new System.Drawing.Size(6, 51);
this.toolStripSeparator4.Visible = false;
//
// tsbOperationRecover
//
this.tsbOperationRecover.Font = new System.Drawing.Font("微软雅黑", 9F);
this.tsbOperationRecover.Image = global::AIMS.Properties.Resources._回顾恢复;
this.tsbOperationRecover.ImageTransparentColor = System.Drawing.Color.Magenta;
this.tsbOperationRecover.Name = "tsbOperationRecover";
this.tsbOperationRecover.Size = new System.Drawing.Size(68, 48);
this.tsbOperationRecover.Text = " 回顾恢复";
this.tsbOperationRecover.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
this.tsbOperationRecover.Visible = false;
this.tsbOperationRecover.Click += new System.EventHandler(this.tsbOperationRecover_Click);
//
// toolStripSeparator3
//
this.toolStripSeparator3.Name = "toolStripSeparator3";
this.toolStripSeparator3.Size = new System.Drawing.Size(6, 51);
this.toolStripSeparator3.Visible = false;
//
// tspBAGD
//
@ -228,22 +250,6 @@
this.toolStripSeparator5.Name = "toolStripSeparator5";
this.toolStripSeparator5.Size = new System.Drawing.Size(6, 51);
//
// tsbOperationRecover
//
this.tsbOperationRecover.Font = new System.Drawing.Font("微软雅黑", 9F);
this.tsbOperationRecover.Image = global::AIMS.Properties.Resources._回顾恢复;
this.tsbOperationRecover.ImageTransparentColor = System.Drawing.Color.Magenta;
this.tsbOperationRecover.Name = "tsbOperationRecover";
this.tsbOperationRecover.Size = new System.Drawing.Size(68, 48);
this.tsbOperationRecover.Text = " 回顾恢复";
this.tsbOperationRecover.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
this.tsbOperationRecover.Click += new System.EventHandler(this.tsbOperationRecover_Click);
//
// toolStripSeparator3
//
this.toolStripSeparator3.Name = "toolStripSeparator3";
this.toolStripSeparator3.Size = new System.Drawing.Size(6, 51);
//
// tsbExit
//
this.tsbExit.Font = new System.Drawing.Font("微软雅黑", 9F);

View File

@ -38,12 +38,12 @@
this.btnCancelIn = new System.Windows.Forms.Button();
this.btnCancelOperation = new System.Windows.Forms.Button();
this.btnTemplate = new System.Windows.Forms.Button();
this.button6 = new System.Windows.Forms.Button();
this.btnBloodGasAnalysis = new System.Windows.Forms.Button();
this.button6 = new System.Windows.Forms.Button();
this.btnOperationInfo = new System.Windows.Forms.Button();
this.btnOutputLiquids = new System.Windows.Forms.Button();
this.btnAddEvents = new System.Windows.Forms.Button();
this.btnDrug = new System.Windows.Forms.Button();
this.btnOperationInfo = new System.Windows.Forms.Button();
this.btnSelectPatient = new System.Windows.Forms.Button();
this.panel4 = new System.Windows.Forms.Panel();
this.btnChage = new System.Windows.Forms.Button();
@ -162,7 +162,7 @@
this.panel2.Dock = System.Windows.Forms.DockStyle.Top;
this.panel2.Location = new System.Drawing.Point(0, 0);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(1360, 10);
this.panel2.Size = new System.Drawing.Size(1673, 10);
this.panel2.TabIndex = 1;
this.panel2.Visible = false;
//
@ -185,12 +185,12 @@
this.panel14.Controls.Add(this.btnCancelIn);
this.panel14.Controls.Add(this.btnCancelOperation);
this.panel14.Controls.Add(this.btnTemplate);
this.panel14.Controls.Add(this.button6);
this.panel14.Controls.Add(this.btnBloodGasAnalysis);
this.panel14.Controls.Add(this.button6);
this.panel14.Controls.Add(this.btnOperationInfo);
this.panel14.Controls.Add(this.btnOutputLiquids);
this.panel14.Controls.Add(this.btnAddEvents);
this.panel14.Controls.Add(this.btnDrug);
this.panel14.Controls.Add(this.btnOperationInfo);
this.panel14.Controls.Add(this.btnSelectPatient);
this.panel14.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel14.Location = new System.Drawing.Point(0, 0);
@ -298,26 +298,6 @@
this.btnTemplate.UseVisualStyleBackColor = false;
this.btnTemplate.Click += new System.EventHandler(this.btnTemplate_Click);
//
// button6
//
this.button6.BackColor = System.Drawing.Color.Transparent;
this.button6.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None;
this.button6.Cursor = System.Windows.Forms.Cursors.Hand;
this.button6.Dock = System.Windows.Forms.DockStyle.Top;
this.button6.FlatAppearance.BorderSize = 0;
this.button6.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.button6.Font = new System.Drawing.Font("微软雅黑", 11F);
this.button6.ForeColor = System.Drawing.Color.DimGray;
this.button6.Image = global::AIMS.Properties.Resources.;
this.button6.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.button6.Location = new System.Drawing.Point(0, 300);
this.button6.Name = "button6";
this.button6.Size = new System.Drawing.Size(160, 50);
this.button6.TabIndex = 9;
this.button6.Text = " 质控指标";
this.button6.UseVisualStyleBackColor = false;
this.button6.Click += new System.EventHandler(this.button6_Click);
//
// btnBloodGasAnalysis
//
this.btnBloodGasAnalysis.BackColor = System.Drawing.Color.Transparent;
@ -330,7 +310,7 @@
this.btnBloodGasAnalysis.ForeColor = System.Drawing.Color.DimGray;
this.btnBloodGasAnalysis.Image = global::AIMS.Properties.Resources.;
this.btnBloodGasAnalysis.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.btnBloodGasAnalysis.Location = new System.Drawing.Point(0, 250);
this.btnBloodGasAnalysis.Location = new System.Drawing.Point(0, 300);
this.btnBloodGasAnalysis.Name = "btnBloodGasAnalysis";
this.btnBloodGasAnalysis.Size = new System.Drawing.Size(160, 50);
this.btnBloodGasAnalysis.TabIndex = 8;
@ -338,6 +318,46 @@
this.btnBloodGasAnalysis.UseVisualStyleBackColor = false;
this.btnBloodGasAnalysis.Click += new System.EventHandler(this.btnBloodGasAnalysis_Click);
//
// button6
//
this.button6.BackColor = System.Drawing.Color.Transparent;
this.button6.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None;
this.button6.Cursor = System.Windows.Forms.Cursors.Hand;
this.button6.Dock = System.Windows.Forms.DockStyle.Top;
this.button6.FlatAppearance.BorderSize = 0;
this.button6.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.button6.Font = new System.Drawing.Font("微软雅黑", 11F);
this.button6.ForeColor = System.Drawing.Color.DimGray;
this.button6.Image = global::AIMS.Properties.Resources.;
this.button6.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.button6.Location = new System.Drawing.Point(0, 250);
this.button6.Name = "button6";
this.button6.Size = new System.Drawing.Size(160, 50);
this.button6.TabIndex = 9;
this.button6.Text = " 质控指标";
this.button6.UseVisualStyleBackColor = false;
this.button6.Click += new System.EventHandler(this.button6_Click);
//
// btnOperationInfo
//
this.btnOperationInfo.BackColor = System.Drawing.Color.Transparent;
this.btnOperationInfo.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None;
this.btnOperationInfo.Cursor = System.Windows.Forms.Cursors.Hand;
this.btnOperationInfo.Dock = System.Windows.Forms.DockStyle.Top;
this.btnOperationInfo.FlatAppearance.BorderSize = 0;
this.btnOperationInfo.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnOperationInfo.Font = new System.Drawing.Font("微软雅黑", 11F);
this.btnOperationInfo.ForeColor = System.Drawing.Color.DimGray;
this.btnOperationInfo.Image = global::AIMS.Properties.Resources.;
this.btnOperationInfo.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.btnOperationInfo.Location = new System.Drawing.Point(0, 200);
this.btnOperationInfo.Name = "btnOperationInfo";
this.btnOperationInfo.Size = new System.Drawing.Size(160, 50);
this.btnOperationInfo.TabIndex = 4;
this.btnOperationInfo.Text = " 手术信息";
this.btnOperationInfo.UseVisualStyleBackColor = false;
this.btnOperationInfo.Click += new System.EventHandler(this.btnOperationInfo_Click);
//
// btnOutputLiquids
//
this.btnOutputLiquids.BackColor = System.Drawing.Color.Transparent;
@ -350,7 +370,7 @@
this.btnOutputLiquids.ForeColor = System.Drawing.Color.DimGray;
this.btnOutputLiquids.Image = global::AIMS.Properties.Resources.;
this.btnOutputLiquids.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.btnOutputLiquids.Location = new System.Drawing.Point(0, 200);
this.btnOutputLiquids.Location = new System.Drawing.Point(0, 150);
this.btnOutputLiquids.Name = "btnOutputLiquids";
this.btnOutputLiquids.Size = new System.Drawing.Size(160, 50);
this.btnOutputLiquids.TabIndex = 7;
@ -370,7 +390,7 @@
this.btnAddEvents.ForeColor = System.Drawing.Color.DimGray;
this.btnAddEvents.Image = global::AIMS.Properties.Resources.;
this.btnAddEvents.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.btnAddEvents.Location = new System.Drawing.Point(0, 150);
this.btnAddEvents.Location = new System.Drawing.Point(0, 100);
this.btnAddEvents.Name = "btnAddEvents";
this.btnAddEvents.Size = new System.Drawing.Size(160, 50);
this.btnAddEvents.TabIndex = 6;
@ -390,7 +410,7 @@
this.btnDrug.ForeColor = System.Drawing.Color.DimGray;
this.btnDrug.Image = global::AIMS.Properties.Resources.;
this.btnDrug.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.btnDrug.Location = new System.Drawing.Point(0, 100);
this.btnDrug.Location = new System.Drawing.Point(0, 50);
this.btnDrug.Name = "btnDrug";
this.btnDrug.Size = new System.Drawing.Size(160, 50);
this.btnDrug.TabIndex = 5;
@ -398,26 +418,6 @@
this.btnDrug.UseVisualStyleBackColor = false;
this.btnDrug.Click += new System.EventHandler(this.btnDrug_Click);
//
// btnOperationInfo
//
this.btnOperationInfo.BackColor = System.Drawing.Color.Transparent;
this.btnOperationInfo.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None;
this.btnOperationInfo.Cursor = System.Windows.Forms.Cursors.Hand;
this.btnOperationInfo.Dock = System.Windows.Forms.DockStyle.Top;
this.btnOperationInfo.FlatAppearance.BorderSize = 0;
this.btnOperationInfo.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnOperationInfo.Font = new System.Drawing.Font("微软雅黑", 11F);
this.btnOperationInfo.ForeColor = System.Drawing.Color.DimGray;
this.btnOperationInfo.Image = global::AIMS.Properties.Resources.;
this.btnOperationInfo.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.btnOperationInfo.Location = new System.Drawing.Point(0, 50);
this.btnOperationInfo.Name = "btnOperationInfo";
this.btnOperationInfo.Size = new System.Drawing.Size(160, 50);
this.btnOperationInfo.TabIndex = 4;
this.btnOperationInfo.Text = " 手术信息";
this.btnOperationInfo.UseVisualStyleBackColor = false;
this.btnOperationInfo.Click += new System.EventHandler(this.btnOperationInfo_Click);
//
// btnSelectPatient
//
this.btnSelectPatient.BackColor = System.Drawing.Color.Transparent;
@ -466,7 +466,7 @@
this.panel4.Controls.Add(this.label1);
this.panel4.Dock = System.Windows.Forms.DockStyle.Right;
this.panel4.Font = new System.Drawing.Font("宋体", 10.5F);
this.panel4.Location = new System.Drawing.Point(1200, 10);
this.panel4.Location = new System.Drawing.Point(1513, 10);
this.panel4.Name = "panel4";
this.panel4.Size = new System.Drawing.Size(160, 859);
this.panel4.TabIndex = 3;
@ -816,7 +816,7 @@
this.panel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel1.Location = new System.Drawing.Point(0, 0);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(1360, 869);
this.panel1.Size = new System.Drawing.Size(1673, 869);
this.panel1.TabIndex = 0;
//
// panel5
@ -829,7 +829,7 @@
this.panel5.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel5.Location = new System.Drawing.Point(160, 10);
this.panel5.Name = "panel5";
this.panel5.Size = new System.Drawing.Size(1040, 859);
this.panel5.Size = new System.Drawing.Size(1353, 859);
this.panel5.TabIndex = 4;
//
// panel8
@ -841,7 +841,7 @@
this.panel8.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel8.Location = new System.Drawing.Point(0, 58);
this.panel8.Name = "panel8";
this.panel8.Size = new System.Drawing.Size(1038, 759);
this.panel8.Size = new System.Drawing.Size(1351, 759);
this.panel8.TabIndex = 2;
this.panel8.Scroll += new System.Windows.Forms.ScrollEventHandler(this.panel8_Scroll);
//
@ -897,7 +897,7 @@
this.panel7.Dock = System.Windows.Forms.DockStyle.Bottom;
this.panel7.Location = new System.Drawing.Point(0, 817);
this.panel7.Name = "panel7";
this.panel7.Size = new System.Drawing.Size(1038, 40);
this.panel7.Size = new System.Drawing.Size(1351, 40);
this.panel7.TabIndex = 1;
//
// panel21
@ -910,7 +910,7 @@
this.panel21.Controls.Add(this.btnUpPage);
this.panel21.Controls.Add(this.plRefresh);
this.panel21.Dock = System.Windows.Forms.DockStyle.Right;
this.panel21.Location = new System.Drawing.Point(697, 0);
this.panel21.Location = new System.Drawing.Point(1010, 0);
this.panel21.Name = "panel21";
this.panel21.Size = new System.Drawing.Size(341, 40);
this.panel21.TabIndex = 10;
@ -1050,7 +1050,7 @@
this.plTitleEventTime.Dock = System.Windows.Forms.DockStyle.Top;
this.plTitleEventTime.Location = new System.Drawing.Point(0, 0);
this.plTitleEventTime.Name = "plTitleEventTime";
this.plTitleEventTime.Size = new System.Drawing.Size(1038, 58);
this.plTitleEventTime.Size = new System.Drawing.Size(1351, 58);
this.plTitleEventTime.TabIndex = 0;
//
// panel13
@ -1080,7 +1080,7 @@
this.txtOutRoom.Format = DevComponents.Editors.eDateTimePickerFormat.Custom;
this.txtOutRoom.InputHorizontalAlignment = DevComponents.Editors.eHorizontalAlignment.Center;
this.txtOutRoom.IsPopupCalendarOpen = false;
this.txtOutRoom.Location = new System.Drawing.Point(40, 23);
this.txtOutRoom.Location = new System.Drawing.Point(42, 23);
this.txtOutRoom.Margin = new System.Windows.Forms.Padding(6, 0, 6, 6);
//
//
@ -1124,9 +1124,9 @@
this.picOutRoom.BackColor = System.Drawing.Color.Transparent;
this.picOutRoom.BackgroundImage = global::AIMS.Properties.Resources.;
this.picOutRoom.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom;
this.picOutRoom.Location = new System.Drawing.Point(5, 12);
this.picOutRoom.Location = new System.Drawing.Point(2, 10);
this.picOutRoom.Name = "picOutRoom";
this.picOutRoom.Size = new System.Drawing.Size(28, 28);
this.picOutRoom.Size = new System.Drawing.Size(34, 33);
this.picOutRoom.TabIndex = 42;
this.picOutRoom.TabStop = false;
//
@ -1173,7 +1173,7 @@
this.txtOperationBegin.Format = DevComponents.Editors.eDateTimePickerFormat.Custom;
this.txtOperationBegin.InputHorizontalAlignment = DevComponents.Editors.eHorizontalAlignment.Center;
this.txtOperationBegin.IsPopupCalendarOpen = false;
this.txtOperationBegin.Location = new System.Drawing.Point(40, 23);
this.txtOperationBegin.Location = new System.Drawing.Point(42, 23);
this.txtOperationBegin.Margin = new System.Windows.Forms.Padding(6, 0, 6, 6);
//
//
@ -1217,9 +1217,9 @@
this.picOpeBegin.BackColor = System.Drawing.Color.Transparent;
this.picOpeBegin.BackgroundImage = global::AIMS.Properties.Resources.;
this.picOpeBegin.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom;
this.picOpeBegin.Location = new System.Drawing.Point(5, 12);
this.picOpeBegin.Location = new System.Drawing.Point(2, 10);
this.picOpeBegin.Name = "picOpeBegin";
this.picOpeBegin.Size = new System.Drawing.Size(28, 28);
this.picOpeBegin.Size = new System.Drawing.Size(34, 33);
this.picOpeBegin.TabIndex = 42;
this.picOpeBegin.TabStop = false;
//
@ -1266,7 +1266,7 @@
this.txtBG.Format = DevComponents.Editors.eDateTimePickerFormat.Custom;
this.txtBG.InputHorizontalAlignment = DevComponents.Editors.eHorizontalAlignment.Center;
this.txtBG.IsPopupCalendarOpen = false;
this.txtBG.Location = new System.Drawing.Point(40, 26);
this.txtBG.Location = new System.Drawing.Point(42, 26);
this.txtBG.Margin = new System.Windows.Forms.Padding(6, 0, 6, 6);
//
//
@ -1310,9 +1310,9 @@
this.picBG.BackColor = System.Drawing.Color.Transparent;
this.picBG.BackgroundImage = global::AIMS.Properties.Resources.;
this.picBG.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom;
this.picBG.Location = new System.Drawing.Point(5, 12);
this.picBG.Location = new System.Drawing.Point(2, 10);
this.picBG.Name = "picBG";
this.picBG.Size = new System.Drawing.Size(28, 28);
this.picBG.Size = new System.Drawing.Size(34, 33);
this.picBG.TabIndex = 42;
this.picBG.TabStop = false;
//
@ -1359,7 +1359,7 @@
this.txtAnaesthesiaEnd.Format = DevComponents.Editors.eDateTimePickerFormat.Custom;
this.txtAnaesthesiaEnd.InputHorizontalAlignment = DevComponents.Editors.eHorizontalAlignment.Center;
this.txtAnaesthesiaEnd.IsPopupCalendarOpen = false;
this.txtAnaesthesiaEnd.Location = new System.Drawing.Point(40, 23);
this.txtAnaesthesiaEnd.Location = new System.Drawing.Point(42, 23);
this.txtAnaesthesiaEnd.Margin = new System.Windows.Forms.Padding(6, 0, 6, 6);
//
//
@ -1403,9 +1403,9 @@
this.picAnesEnd.BackColor = System.Drawing.Color.Transparent;
this.picAnesEnd.BackgroundImage = global::AIMS.Properties.Resources.;
this.picAnesEnd.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom;
this.picAnesEnd.Location = new System.Drawing.Point(5, 12);
this.picAnesEnd.Location = new System.Drawing.Point(2, 10);
this.picAnesEnd.Name = "picAnesEnd";
this.picAnesEnd.Size = new System.Drawing.Size(28, 28);
this.picAnesEnd.Size = new System.Drawing.Size(34, 33);
this.picAnesEnd.TabIndex = 42;
this.picAnesEnd.TabStop = false;
//
@ -1444,7 +1444,7 @@
this.cmbCGType.Items.AddRange(new object[] {
"插管",
"喉罩"});
this.cmbCGType.Location = new System.Drawing.Point(40, 0);
this.cmbCGType.Location = new System.Drawing.Point(42, 0);
this.cmbCGType.Name = "cmbCGType";
this.cmbCGType.Size = new System.Drawing.Size(101, 25);
this.cmbCGType.TabIndex = 47;
@ -1465,7 +1465,7 @@
this.txtCG.Format = DevComponents.Editors.eDateTimePickerFormat.Custom;
this.txtCG.InputHorizontalAlignment = DevComponents.Editors.eHorizontalAlignment.Center;
this.txtCG.IsPopupCalendarOpen = false;
this.txtCG.Location = new System.Drawing.Point(40, 26);
this.txtCG.Location = new System.Drawing.Point(42, 26);
this.txtCG.Margin = new System.Windows.Forms.Padding(6, 0, 6, 6);
//
//
@ -1509,9 +1509,9 @@
this.picCG.BackColor = System.Drawing.Color.Transparent;
this.picCG.BackgroundImage = global::AIMS.Properties.Resources.;
this.picCG.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom;
this.picCG.Location = new System.Drawing.Point(5, 12);
this.picCG.Location = new System.Drawing.Point(2, 10);
this.picCG.Name = "picCG";
this.picCG.Size = new System.Drawing.Size(28, 28);
this.picCG.Size = new System.Drawing.Size(34, 33);
this.picCG.TabIndex = 42;
this.picCG.TabStop = false;
//
@ -1542,7 +1542,7 @@
this.txtAnaesthesiaBegin.Format = DevComponents.Editors.eDateTimePickerFormat.Custom;
this.txtAnaesthesiaBegin.InputHorizontalAlignment = DevComponents.Editors.eHorizontalAlignment.Center;
this.txtAnaesthesiaBegin.IsPopupCalendarOpen = false;
this.txtAnaesthesiaBegin.Location = new System.Drawing.Point(40, 23);
this.txtAnaesthesiaBegin.Location = new System.Drawing.Point(42, 23);
this.txtAnaesthesiaBegin.Margin = new System.Windows.Forms.Padding(6, 0, 6, 6);
//
//
@ -1586,9 +1586,9 @@
this.picAnesBegin.BackColor = System.Drawing.Color.Transparent;
this.picAnesBegin.BackgroundImage = global::AIMS.Properties.Resources.;
this.picAnesBegin.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom;
this.picAnesBegin.Location = new System.Drawing.Point(5, 12);
this.picAnesBegin.Location = new System.Drawing.Point(2, 10);
this.picAnesBegin.Name = "picAnesBegin";
this.picAnesBegin.Size = new System.Drawing.Size(28, 28);
this.picAnesBegin.Size = new System.Drawing.Size(34, 33);
this.picAnesBegin.TabIndex = 42;
this.picAnesBegin.TabStop = false;
//
@ -1635,7 +1635,7 @@
this.txtOperationEnd.Format = DevComponents.Editors.eDateTimePickerFormat.Custom;
this.txtOperationEnd.InputHorizontalAlignment = DevComponents.Editors.eHorizontalAlignment.Center;
this.txtOperationEnd.IsPopupCalendarOpen = false;
this.txtOperationEnd.Location = new System.Drawing.Point(40, 23);
this.txtOperationEnd.Location = new System.Drawing.Point(42, 23);
this.txtOperationEnd.Margin = new System.Windows.Forms.Padding(6, 0, 6, 6);
//
//
@ -1679,9 +1679,9 @@
this.picOpeEnd.BackColor = System.Drawing.Color.Transparent;
this.picOpeEnd.BackgroundImage = global::AIMS.Properties.Resources.;
this.picOpeEnd.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom;
this.picOpeEnd.Location = new System.Drawing.Point(5, 12);
this.picOpeEnd.Location = new System.Drawing.Point(2, 10);
this.picOpeEnd.Name = "picOpeEnd";
this.picOpeEnd.Size = new System.Drawing.Size(28, 28);
this.picOpeEnd.Size = new System.Drawing.Size(34, 33);
this.picOpeEnd.TabIndex = 42;
this.picOpeEnd.TabStop = false;
//
@ -1728,7 +1728,7 @@
this.txtInRoom.Format = DevComponents.Editors.eDateTimePickerFormat.Custom;
this.txtInRoom.InputHorizontalAlignment = DevComponents.Editors.eHorizontalAlignment.Center;
this.txtInRoom.IsPopupCalendarOpen = false;
this.txtInRoom.Location = new System.Drawing.Point(40, 23);
this.txtInRoom.Location = new System.Drawing.Point(42, 23);
this.txtInRoom.Margin = new System.Windows.Forms.Padding(6, 0, 6, 6);
//
//
@ -1772,9 +1772,9 @@
this.picInRoom.BackColor = System.Drawing.Color.Transparent;
this.picInRoom.BackgroundImage = global::AIMS.Properties.Resources.;
this.picInRoom.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom;
this.picInRoom.Location = new System.Drawing.Point(5, 12);
this.picInRoom.Location = new System.Drawing.Point(2, 10);
this.picInRoom.Name = "picInRoom";
this.picInRoom.Size = new System.Drawing.Size(28, 28);
this.picInRoom.Size = new System.Drawing.Size(34, 33);
this.picInRoom.TabIndex = 42;
this.picInRoom.TabStop = false;
//
@ -1805,7 +1805,7 @@
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(1360, 869);
this.ClientSize = new System.Drawing.Size(1673, 869);
this.Controls.Add(this.panel1);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.Name = "frmAnasRecordBillNew";

View File

@ -658,6 +658,7 @@
this.label35.Size = new System.Drawing.Size(65, 20);
this.label35.TabIndex = 855;
this.label35.Text = "手术体位";
this.label35.Visible = false;
//
// txtOperationSiteId
//
@ -684,6 +685,7 @@
this.txtOperationSiteId.Name = "txtOperationSiteId";
this.txtOperationSiteId.Size = new System.Drawing.Size(251, 22);
this.txtOperationSiteId.TabIndex = 12;
this.txtOperationSiteId.Visible = false;
this.txtOperationSiteId.Click += new System.EventHandler(this.txtOperationPosition_TextChanged);
this.txtOperationSiteId.DoubleClick += new System.EventHandler(this.txtOperationPosition_TextChanged);
//

View File

@ -40,21 +40,6 @@ namespace DrawGraph
this.superTabControlPanel1 = new DevComponents.DotNetBar.SuperTabControlPanel();
this.panelExZKZB = new DevComponents.DotNetBar.PanelEx();
this.dgvSetting = new DevComponents.DotNetBar.Controls.DataGridViewX();
this.spJHYCS = new DevComponents.DotNetBar.SuperTabItem();
this.superTabControlPanel2 = new DevComponents.DotNetBar.SuperTabControlPanel();
this.panelJHYSJXS = new DevComponents.DotNetBar.PanelEx();
this.spJHYSJXS = new DevComponents.DotNetBar.SuperTabItem();
this.colorDialog1 = new System.Windows.Forms.ColorDialog();
this.imageList1 = new System.Windows.Forms.ImageList(this.components);
this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn6 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn7 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn8 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn9 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Id = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.PName = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Enname = new System.Windows.Forms.DataGridViewTextBoxColumn();
@ -71,6 +56,21 @@ namespace DrawGraph
this.Unit = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.YAisx = new DevComponents.DotNetBar.Controls.DataGridViewIntegerInputColumn();
this.PhysioOrder = new DevComponents.DotNetBar.Controls.DataGridViewIntegerInputColumn();
this.spJHYCS = new DevComponents.DotNetBar.SuperTabItem();
this.superTabControlPanel2 = new DevComponents.DotNetBar.SuperTabControlPanel();
this.panelJHYSJXS = new DevComponents.DotNetBar.PanelEx();
this.spJHYSJXS = new DevComponents.DotNetBar.SuperTabItem();
this.colorDialog1 = new System.Windows.Forms.ColorDialog();
this.imageList1 = new System.Windows.Forms.ImageList(this.components);
this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn6 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn7 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn8 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn9 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.panel1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.superTabControl1)).BeginInit();
this.superTabControl1.SuspendLayout();
@ -223,162 +223,6 @@ namespace DrawGraph
this.dgvSetting.TabIndex = 0;
this.dgvSetting.CellDoubleClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvSetting_CellDoubleClick);
//
// spJHYCS
//
this.spJHYCS.AttachedControl = this.superTabControlPanel1;
this.spJHYCS.GlobalItem = false;
this.spJHYCS.Name = "spJHYCS";
this.spJHYCS.Text = "监护仪参数";
//
// superTabControlPanel2
//
this.superTabControlPanel2.Controls.Add(this.panelJHYSJXS);
this.superTabControlPanel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.superTabControlPanel2.Location = new System.Drawing.Point(0, 28);
this.superTabControlPanel2.Name = "superTabControlPanel2";
this.superTabControlPanel2.Size = new System.Drawing.Size(1060, 436);
this.superTabControlPanel2.TabIndex = 0;
this.superTabControlPanel2.TabItem = this.spJHYSJXS;
//
// panelJHYSJXS
//
this.panelJHYSJXS.CanvasColor = System.Drawing.SystemColors.Control;
this.panelJHYSJXS.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled;
this.panelJHYSJXS.DisabledBackColor = System.Drawing.Color.Empty;
this.panelJHYSJXS.Dock = System.Windows.Forms.DockStyle.Fill;
this.panelJHYSJXS.Location = new System.Drawing.Point(0, 0);
this.panelJHYSJXS.Name = "panelJHYSJXS";
this.panelJHYSJXS.Size = new System.Drawing.Size(1060, 436);
this.panelJHYSJXS.Style.Alignment = System.Drawing.StringAlignment.Center;
this.panelJHYSJXS.Style.BackColor1.ColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBackground;
this.panelJHYSJXS.Style.BackColor2.ColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBackground2;
this.panelJHYSJXS.Style.Border = DevComponents.DotNetBar.eBorderType.SingleLine;
this.panelJHYSJXS.Style.BorderColor.ColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBorder;
this.panelJHYSJXS.Style.ForeColor.ColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelText;
this.panelJHYSJXS.Style.GradientAngle = 90;
this.panelJHYSJXS.TabIndex = 0;
//
// spJHYSJXS
//
this.spJHYSJXS.AttachedControl = this.superTabControlPanel2;
this.spJHYSJXS.GlobalItem = false;
this.spJHYSJXS.Name = "spJHYSJXS";
this.spJHYSJXS.Text = "监护仪数据显示";
//
// imageList1
//
this.imageList1.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageList1.ImageStream")));
this.imageList1.TransparentColor = System.Drawing.Color.Transparent;
this.imageList1.Images.SetKeyName(0, "bg.png");
this.imageList1.Images.SetKeyName(1, "Circle.png");
this.imageList1.Images.SetKeyName(2, "Close.png");
this.imageList1.Images.SetKeyName(3, "cr.png");
this.imageList1.Images.SetKeyName(4, "cssj.png");
this.imageList1.Images.SetKeyName(5, "Dia.png");
this.imageList1.Images.SetKeyName(6, "dmy.png");
this.imageList1.Images.SetKeyName(7, "expand1.png");
this.imageList1.Images.SetKeyName(8, "expand2.png");
this.imageList1.Images.SetKeyName(9, "expand3.png");
this.imageList1.Images.SetKeyName(10, "HR.png");
this.imageList1.Images.SetKeyName(11, "jxtq.png");
this.imageList1.Images.SetKeyName(12, "MAP.png");
this.imageList1.Images.SetKeyName(13, "mb.png");
this.imageList1.Images.SetKeyName(14, "ms.png");
this.imageList1.Images.SetKeyName(15, "mz.png");
this.imageList1.Images.SetKeyName(16, "mzjs.png");
this.imageList1.Images.SetKeyName(17, "mzks.png");
this.imageList1.Images.SetKeyName(18, "ok.png");
this.imageList1.Images.SetKeyName(19, "pjy.png");
this.imageList1.Images.SetKeyName(20, "Resp.png");
this.imageList1.Images.SetKeyName(21, "rssj.png");
this.imageList1.Images.SetKeyName(22, "sb.png");
this.imageList1.Images.SetKeyName(23, "sb2.png");
this.imageList1.Images.SetKeyName(24, "sb3.png");
this.imageList1.Images.SetKeyName(25, "SPO2.png");
this.imageList1.Images.SetKeyName(26, "SPO2f.png");
this.imageList1.Images.SetKeyName(27, "ss.png");
this.imageList1.Images.SetKeyName(28, "ss1.png");
this.imageList1.Images.SetKeyName(29, "ssjs.png");
this.imageList1.Images.SetKeyName(30, "ssks.png");
this.imageList1.Images.SetKeyName(31, "sy.png");
this.imageList1.Images.SetKeyName(32, "sy2.png");
this.imageList1.Images.SetKeyName(33, "sy3.png");
this.imageList1.Images.SetKeyName(34, "Sys.png");
this.imageList1.Images.SetKeyName(35, "T.png");
this.imageList1.Images.SetKeyName(36, "t1.png");
this.imageList1.Images.SetKeyName(37, "Temp.png");
this.imageList1.Images.SetKeyName(38, "Temp2.png");
this.imageList1.Images.SetKeyName(39, "Triangle.png");
this.imageList1.Images.SetKeyName(40, "TriangleDown.png");
this.imageList1.Images.SetKeyName(41, "xl.png");
this.imageList1.Images.SetKeyName(42, "zg.png");
this.imageList1.Images.SetKeyName(43, "zy.png");
//
// dataGridViewTextBoxColumn1
//
this.dataGridViewTextBoxColumn1.DataPropertyName = "Id";
this.dataGridViewTextBoxColumn1.HeaderText = "Id";
this.dataGridViewTextBoxColumn1.Name = "dataGridViewTextBoxColumn1";
this.dataGridViewTextBoxColumn1.ReadOnly = true;
this.dataGridViewTextBoxColumn1.Visible = false;
//
// dataGridViewTextBoxColumn2
//
this.dataGridViewTextBoxColumn2.DataPropertyName = "Name";
this.dataGridViewTextBoxColumn2.HeaderText = "名称";
this.dataGridViewTextBoxColumn2.Name = "dataGridViewTextBoxColumn2";
this.dataGridViewTextBoxColumn2.ReadOnly = true;
//
// dataGridViewTextBoxColumn3
//
this.dataGridViewTextBoxColumn3.DataPropertyName = "Enname";
this.dataGridViewTextBoxColumn3.HeaderText = "简码";
this.dataGridViewTextBoxColumn3.Name = "dataGridViewTextBoxColumn3";
this.dataGridViewTextBoxColumn3.ReadOnly = true;
this.dataGridViewTextBoxColumn3.Width = 80;
//
// dataGridViewTextBoxColumn4
//
this.dataGridViewTextBoxColumn4.DataPropertyName = "imgPath";
this.dataGridViewTextBoxColumn4.HeaderText = "图片";
this.dataGridViewTextBoxColumn4.Name = "dataGridViewTextBoxColumn4";
this.dataGridViewTextBoxColumn4.Width = 80;
//
// dataGridViewTextBoxColumn5
//
this.dataGridViewTextBoxColumn5.DataPropertyName = "color";
this.dataGridViewTextBoxColumn5.HeaderText = "线条颜色";
this.dataGridViewTextBoxColumn5.Name = "dataGridViewTextBoxColumn5";
this.dataGridViewTextBoxColumn5.Width = 70;
//
// dataGridViewTextBoxColumn6
//
this.dataGridViewTextBoxColumn6.DataPropertyName = "HighLimit";
this.dataGridViewTextBoxColumn6.HeaderText = "上限";
this.dataGridViewTextBoxColumn6.Name = "dataGridViewTextBoxColumn6";
this.dataGridViewTextBoxColumn6.Width = 70;
//
// dataGridViewTextBoxColumn7
//
this.dataGridViewTextBoxColumn7.DataPropertyName = "LowLimit";
this.dataGridViewTextBoxColumn7.HeaderText = "下限";
this.dataGridViewTextBoxColumn7.Name = "dataGridViewTextBoxColumn7";
this.dataGridViewTextBoxColumn7.Width = 70;
//
// dataGridViewTextBoxColumn8
//
this.dataGridViewTextBoxColumn8.DataPropertyName = "WarningHighLimit";
this.dataGridViewTextBoxColumn8.HeaderText = "报警上限";
this.dataGridViewTextBoxColumn8.Name = "dataGridViewTextBoxColumn8";
this.dataGridViewTextBoxColumn8.Width = 60;
//
// dataGridViewTextBoxColumn9
//
this.dataGridViewTextBoxColumn9.DataPropertyName = "WarningLowLimit";
this.dataGridViewTextBoxColumn9.HeaderText = "报警下限";
this.dataGridViewTextBoxColumn9.Name = "dataGridViewTextBoxColumn9";
this.dataGridViewTextBoxColumn9.Width = 60;
//
// Id
//
this.Id.DataPropertyName = "Id";
@ -550,6 +394,165 @@ namespace DrawGraph
this.PhysioOrder.Resizable = System.Windows.Forms.DataGridViewTriState.True;
this.PhysioOrder.Width = 70;
//
// spJHYCS
//
this.spJHYCS.AttachedControl = this.superTabControlPanel1;
this.spJHYCS.GlobalItem = false;
this.spJHYCS.Name = "spJHYCS";
this.spJHYCS.Text = "监护仪参数";
//
// superTabControlPanel2
//
this.superTabControlPanel2.Controls.Add(this.panelJHYSJXS);
this.superTabControlPanel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.superTabControlPanel2.Location = new System.Drawing.Point(0, 28);
this.superTabControlPanel2.Name = "superTabControlPanel2";
this.superTabControlPanel2.Size = new System.Drawing.Size(1060, 436);
this.superTabControlPanel2.TabIndex = 0;
this.superTabControlPanel2.TabItem = this.spJHYSJXS;
//
// panelJHYSJXS
//
this.panelJHYSJXS.CanvasColor = System.Drawing.SystemColors.Control;
this.panelJHYSJXS.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled;
this.panelJHYSJXS.DisabledBackColor = System.Drawing.Color.Empty;
this.panelJHYSJXS.Dock = System.Windows.Forms.DockStyle.Fill;
this.panelJHYSJXS.Location = new System.Drawing.Point(0, 0);
this.panelJHYSJXS.Name = "panelJHYSJXS";
this.panelJHYSJXS.Size = new System.Drawing.Size(1060, 436);
this.panelJHYSJXS.Style.Alignment = System.Drawing.StringAlignment.Center;
this.panelJHYSJXS.Style.BackColor1.ColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBackground;
this.panelJHYSJXS.Style.BackColor2.ColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBackground2;
this.panelJHYSJXS.Style.Border = DevComponents.DotNetBar.eBorderType.SingleLine;
this.panelJHYSJXS.Style.BorderColor.ColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBorder;
this.panelJHYSJXS.Style.ForeColor.ColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelText;
this.panelJHYSJXS.Style.GradientAngle = 90;
this.panelJHYSJXS.TabIndex = 0;
//
// spJHYSJXS
//
this.spJHYSJXS.AttachedControl = this.superTabControlPanel2;
this.spJHYSJXS.GlobalItem = false;
this.spJHYSJXS.Name = "spJHYSJXS";
this.spJHYSJXS.Text = "监护仪数据显示";
//
// imageList1
//
this.imageList1.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageList1.ImageStream")));
this.imageList1.TransparentColor = System.Drawing.Color.Transparent;
this.imageList1.Images.SetKeyName(0, "bg.png");
this.imageList1.Images.SetKeyName(1, "Circle.png");
this.imageList1.Images.SetKeyName(2, "Close.png");
this.imageList1.Images.SetKeyName(3, "cr.png");
this.imageList1.Images.SetKeyName(4, "cssj.png");
this.imageList1.Images.SetKeyName(5, "Dia.png");
this.imageList1.Images.SetKeyName(6, "dmy.png");
this.imageList1.Images.SetKeyName(7, "expand1.png");
this.imageList1.Images.SetKeyName(8, "expand2.png");
this.imageList1.Images.SetKeyName(9, "expand3.png");
this.imageList1.Images.SetKeyName(10, "fzhx.png");
this.imageList1.Images.SetKeyName(11, "HR.png");
this.imageList1.Images.SetKeyName(12, "jxtq.png");
this.imageList1.Images.SetKeyName(13, "MAP.png");
this.imageList1.Images.SetKeyName(14, "mb.png");
this.imageList1.Images.SetKeyName(15, "ms.png");
this.imageList1.Images.SetKeyName(16, "mz.png");
this.imageList1.Images.SetKeyName(17, "mzjs.png");
this.imageList1.Images.SetKeyName(18, "mzks.png");
this.imageList1.Images.SetKeyName(19, "ok.png");
this.imageList1.Images.SetKeyName(20, "pjy.png");
this.imageList1.Images.SetKeyName(21, "Resp.png");
this.imageList1.Images.SetKeyName(22, "rssj.png");
this.imageList1.Images.SetKeyName(23, "sb.png");
this.imageList1.Images.SetKeyName(24, "sb2.png");
this.imageList1.Images.SetKeyName(25, "sb3.png");
this.imageList1.Images.SetKeyName(26, "SPO2.png");
this.imageList1.Images.SetKeyName(27, "SPO2f.png");
this.imageList1.Images.SetKeyName(28, "ss.png");
this.imageList1.Images.SetKeyName(29, "ss1.png");
this.imageList1.Images.SetKeyName(30, "ssjs.png");
this.imageList1.Images.SetKeyName(31, "ssks.png");
this.imageList1.Images.SetKeyName(32, "sy.png");
this.imageList1.Images.SetKeyName(33, "sy2.png");
this.imageList1.Images.SetKeyName(34, "sy3.png");
this.imageList1.Images.SetKeyName(35, "sy4.png");
this.imageList1.Images.SetKeyName(36, "sy5.png");
this.imageList1.Images.SetKeyName(37, "Sys.png");
this.imageList1.Images.SetKeyName(38, "T.png");
this.imageList1.Images.SetKeyName(39, "t1.png");
this.imageList1.Images.SetKeyName(40, "Temp.png");
this.imageList1.Images.SetKeyName(41, "Temp2.png");
this.imageList1.Images.SetKeyName(42, "Triangle.png");
this.imageList1.Images.SetKeyName(43, "TriangleDown.png");
this.imageList1.Images.SetKeyName(44, "xl.png");
this.imageList1.Images.SetKeyName(45, "zg.png");
this.imageList1.Images.SetKeyName(46, "zy.png");
//
// dataGridViewTextBoxColumn1
//
this.dataGridViewTextBoxColumn1.DataPropertyName = "Id";
this.dataGridViewTextBoxColumn1.HeaderText = "Id";
this.dataGridViewTextBoxColumn1.Name = "dataGridViewTextBoxColumn1";
this.dataGridViewTextBoxColumn1.ReadOnly = true;
this.dataGridViewTextBoxColumn1.Visible = false;
//
// dataGridViewTextBoxColumn2
//
this.dataGridViewTextBoxColumn2.DataPropertyName = "Name";
this.dataGridViewTextBoxColumn2.HeaderText = "名称";
this.dataGridViewTextBoxColumn2.Name = "dataGridViewTextBoxColumn2";
this.dataGridViewTextBoxColumn2.ReadOnly = true;
//
// dataGridViewTextBoxColumn3
//
this.dataGridViewTextBoxColumn3.DataPropertyName = "Enname";
this.dataGridViewTextBoxColumn3.HeaderText = "简码";
this.dataGridViewTextBoxColumn3.Name = "dataGridViewTextBoxColumn3";
this.dataGridViewTextBoxColumn3.ReadOnly = true;
this.dataGridViewTextBoxColumn3.Width = 80;
//
// dataGridViewTextBoxColumn4
//
this.dataGridViewTextBoxColumn4.DataPropertyName = "imgPath";
this.dataGridViewTextBoxColumn4.HeaderText = "图片";
this.dataGridViewTextBoxColumn4.Name = "dataGridViewTextBoxColumn4";
this.dataGridViewTextBoxColumn4.Width = 80;
//
// dataGridViewTextBoxColumn5
//
this.dataGridViewTextBoxColumn5.DataPropertyName = "color";
this.dataGridViewTextBoxColumn5.HeaderText = "线条颜色";
this.dataGridViewTextBoxColumn5.Name = "dataGridViewTextBoxColumn5";
this.dataGridViewTextBoxColumn5.Width = 70;
//
// dataGridViewTextBoxColumn6
//
this.dataGridViewTextBoxColumn6.DataPropertyName = "HighLimit";
this.dataGridViewTextBoxColumn6.HeaderText = "上限";
this.dataGridViewTextBoxColumn6.Name = "dataGridViewTextBoxColumn6";
this.dataGridViewTextBoxColumn6.Width = 70;
//
// dataGridViewTextBoxColumn7
//
this.dataGridViewTextBoxColumn7.DataPropertyName = "LowLimit";
this.dataGridViewTextBoxColumn7.HeaderText = "下限";
this.dataGridViewTextBoxColumn7.Name = "dataGridViewTextBoxColumn7";
this.dataGridViewTextBoxColumn7.Width = 70;
//
// dataGridViewTextBoxColumn8
//
this.dataGridViewTextBoxColumn8.DataPropertyName = "WarningHighLimit";
this.dataGridViewTextBoxColumn8.HeaderText = "报警上限";
this.dataGridViewTextBoxColumn8.Name = "dataGridViewTextBoxColumn8";
this.dataGridViewTextBoxColumn8.Width = 60;
//
// dataGridViewTextBoxColumn9
//
this.dataGridViewTextBoxColumn9.DataPropertyName = "WarningLowLimit";
this.dataGridViewTextBoxColumn9.HeaderText = "报警下限";
this.dataGridViewTextBoxColumn9.Name = "dataGridViewTextBoxColumn9";
this.dataGridViewTextBoxColumn9.Width = 60;
//
// frmPhysiosSetting
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);

View File

@ -175,8 +175,8 @@
<value>
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAA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fABBwHwAQcB+AEfAv8B/gE/Af4BPwH4AR8G/wH8
AR8G/wH+AT8G/wH+AT8B/AEfAv8B9wHxAf4BPwHwAQcC/wHHAfEB/gE/AeEBwwH+AX8BwwHjAf4BPwHH
AfEB/gE/AuMB/gE/Ac8B+QH8AT8B8QHHAgABjgE4AfwBHwHxAccCAAGOATgB+AEfAfgBzwIAAY4BOAH4
AQ8B/AEPAgABjwH4AfABBwH8AQ8B/gE/Ac8B+QHwAQcB/gEfAf4BPwHDAeEB4AEDAf4BHwH+AT8B4AED
AcABAwH/AX8B/gE/AfABBwHAAQMC/wH+AT8B/gE/BP8B/gE/BP8BwAEDBv8BgAEBAfwBHwT/AYEBgAHA
AQEE/wGHAeACwQL/AfwBHwEPAfABwQHhAfkBLwH4Ag8B+AHAAYEB9gHfAfIBJwEfAfgBiAEIAfcB3wHk
ARMBHwH4AYwBGAH3Ad8B5AETAR8B+AGMARgB9gHvAekBSwEfAfgBiAEIAfgBHwHhAUMBDwHwAcABgQL/
AecBcwEHAfABwQHhAv8B8wFnAYMCwAEBAv8B+AEPAYABAQHAAQEC/wH8AR8BwAEBAf4BPwT/AfABDwT/
Cw==
</value>
</data>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />

View File

@ -138,13 +138,13 @@ namespace AIMS.OperationDoing.AnasRecordBill.UI
{
try
{
if (supTabPatient.SelectedTab.Name == "" && dgv.CurrentRow != null)
if (uc.buttonX1.Text == "转入恢复")
{
if (uc.buttonX1.Text == "转入恢复")
if (supTabPatient.SelectedTab.Name == "待恢复" && dgv.SelectedRows.Count > 0)
{
AIMS.OperationDoing.AnasRecoverBill.UI.frmAnasRecoverBillNew frmAnasRecord = new AnasRecoverBill.UI.frmAnasRecoverBillNew();
frmAnasRecord.PatientId = int.Parse(dgv.CurrentRow.Cells["PatientIdColumn"].Value.ToString());
frmAnasRecord.ApplyId = int.Parse(dgv.CurrentRow.Cells["ApplyIdColumn"].Value.ToString());
frmAnasRecord.PatientId = int.Parse(dgv.SelectedRows[0].Cells["PatientIdColumn"].Value.ToString());
frmAnasRecord.ApplyId = int.Parse(dgv.SelectedRows[0].Cells["ApplyIdColumn"].Value.ToString());
frmAnasRecord.RecoverId = RecoverId;
frmAnasRecord.NowRoom = AIMSBLL.BOperationRoom.SelectSingle(int.Parse(uc.Tag.ToString()));
frmAnasRecord.State = AIMSExtension.EditState.ADD;
@ -177,16 +177,17 @@ namespace AIMS.OperationDoing.AnasRecordBill.UI
HelperDB.DbHelperSQL.RollbackTrans();
}
frmAnasRecord.ShowDialog();
FillDgv();
}
else
{
AIMS.OperationDoing.AnasRecoverBill.UI.frmAnasRecoverBillNew frmAnasRecord = new AnasRecoverBill.UI.frmAnasRecoverBillNew();
frmAnasRecord.PatientId = PatientId;
frmAnasRecord.ApplyId = applyId;
frmAnasRecord.NowRoom = AIMSBLL.BOperationRoom.SelectSingle(int.Parse(uc.Tag.ToString()));
frmAnasRecord.State = AIMSExtension.EditState.EDIT;
frmAnasRecord.ShowDialog();
}
}
else
{
AIMS.OperationDoing.AnasRecoverBill.UI.frmAnasRecoverBillNew frmAnasRecord = new AnasRecoverBill.UI.frmAnasRecoverBillNew();
frmAnasRecord.PatientId = PatientId;
frmAnasRecord.ApplyId = applyId;
frmAnasRecord.NowRoom = AIMSBLL.BOperationRoom.SelectSingle(int.Parse(uc.Tag.ToString()));
frmAnasRecord.State = AIMSExtension.EditState.EDIT;
frmAnasRecord.ShowDialog();
FillDgv();
}
}

View File

@ -1,14 +1,13 @@
using System;
using AIMSExtension;
using DevComponents.Editors.DateTimeAdv;
using DrawGraph;
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Drawing.Imaging;
using System.IO;
using System.Linq;
using System.Windows.Forms;
using AIMSExtension;
using DevComponents.Editors.DateTimeAdv;
using DrawGraph;
using Newtonsoft.Json;
namespace AIMS.OperationDoing.AnasRecordBill
{
@ -172,7 +171,152 @@ namespace AIMS.OperationDoing.AnasRecordBill
MemoryStream ms = new MemoryStream(buffer);
Image image = Image.FromStream(ms);
return image;
}
}
//public static void SavePrintDocStatic(Dictionary<string, string> dicList, int modelId, int ApplyId)
//{
// try
// {
// if (modelId != 0) BDocumentManager.DeleteStatic(modelId, ApplyId);
// List<PrintDocStatic> modelStatics = new List<PrintDocStatic>();
// foreach (var key in dicList.Keys)
// {
// PrintDocStatic modelStatic = new PrintDocStatic
// {
// PrintDocId = modelId,
// OperationApplyId = ApplyId,
// Key = key,
// Value = dicList[key],
// OperatorId = PublicMethod.Operator.Id
// };
// modelStatics.Add(modelStatic);
// }
// BDocumentManager.InsertStatic(modelStatics);
// }
// catch (Exception ex)
// {
// }
//}
public static void InsertPicture(GoldPrinter.ExcelAccess excel, FileInfo Img, float PictuteWidth, float PictureHeight)
{
try
{
string imgname = Img.Name.Split('.')[0];
Microsoft.Office.Interop.Excel.Worksheet xSheet = (Microsoft.Office.Interop.Excel.Worksheet)excel.Workbooks.Sheets[1];
Microsoft.Office.Interop.Excel.Range m_objRange = xSheet.Range[imgname, System.Reflection.Missing.Value];
m_objRange.Select();
float PicLeft, PicTop;
PicLeft = Convert.ToSingle(m_objRange.Left);
PicTop = Convert.ToSingle(m_objRange.Top);// + 460;
//参数含义:
//图片路径
//是否链接到文件
//图片插入时是否随文档一起保存
//图片在文档中的坐标位置单位points
//图片显示的宽度和高度单位points
//参数详细信息参见http://msdn2.microsoft.com/zh-cn/library/aa221765(office.11).aspx
//xSheet.Shapes.AddPicture(Img.Attributes.ToString(), MsoTriState.msoFalse,
//MsoTriState.msoTrue, PicLeft, PicTop, PictuteWidth, PictureHeight);
xSheet.Shapes.AddPicture(Img.FullName, Microsoft.Office.Core.MsoTriState.msoFalse, Microsoft.Office.Core.MsoTriState.msoTrue, PicLeft, PicTop, PictuteWidth, PictureHeight);
}
catch (Exception)
{
}
}
public static void SetExcelValue(Control cons, GoldPrinter.ExcelAccess excel, bool addHospitalName = true)
{
try
{
SetExcelValues(cons, excel);
}
catch (Exception ex)
{
PublicMethod.WriteLog(ex);
}
}
/// <summary>
/// 循环控件值写入excel
/// </summary>
/// <param name="cons"></param>
/// <param name="excel"></param>
public static void SetExcelValues(Control cons, GoldPrinter.ExcelAccess excel)
{
try
{
foreach (Control c in cons.Controls)
{
if (c.Controls.Count > 0)
{
SetExcelValues(c, excel);
}
if (c.Tag != null && !c.Tag.Equals(string.Empty))
{
string excelValue = c.Tag.ToString().Split('|')[0];
if (excelValue.Length <= 0 || excelValue == "")
continue;
if (!(char.IsLower(excelValue[0]) || char.IsUpper(excelValue[0])))
{
continue;
}
for (int k = 0; k < excelValue.Length; k++)
{
if (char.IsNumber(excelValue[k]))
{
int p_rowIndex = int.Parse(excelValue.Substring(k, excelValue.Length - k));
string p_colChars = excelValue.Substring(0, excelValue.IndexOf(excelValue[k]));
if (c is TextBox || c is RichTextBox || c is System.Windows.Forms.Label)
{
excel.SetCellText(p_rowIndex, p_colChars, c.Text);
}
else if (c is DateTimePicker)
{
if (((DateTimePicker)c).Enabled == true && ((DateTimePicker)c).Visible == true)
{
string text = c.Text;
if (text == "")
{
try
{
text = ((DateTimePicker)c).Value.ToString("yyyy-MM-dd");
}
catch (Exception) { }
}
excel.SetCellText(p_rowIndex, p_colChars, text);
}
else
{
excel.SetCellText(p_rowIndex, p_colChars, "");
}
}
else if (c is CheckBox)
{
string value = ((CheckBox)c).Checked == true ? "☑" : "□";
excel.SetCellText(p_rowIndex, p_colChars, value);
}
else if (c is ComboBox)
{
excel.SetCellText(p_rowIndex, p_colChars, c.Text);
}
else if (c is RadioButton)
{
string value = ((RadioButton)c).Checked == true ? "☑" : "□";
excel.SetCellText(p_rowIndex, p_colChars, value);
}
break;
}
}
}
}
}
catch (Exception ex)
{
PublicMethod.WriteLog(ex);
}
}
}
public class JsonTextForDoc

View File

@ -360,16 +360,140 @@ namespace AIMS.OperationDoing.AnasRecordBill
#region
public void toolStripButton2_Click(object sender, EventArgs e)
{
SaveReport(false);
SaveReport(false);
try
{
GoldPrinter.ExcelAccess excel = GetExcel();
excel.PrintPreview();
excel.Close();
}
catch (Exception exp)
{
PublicMethod.WriteLog(exp);
}
}
#endregion
#region
public void tsbSaveOperationApply_Click(object sender, EventArgs e)
{
SaveReport(false);
SaveReport(false);
try
{
GoldPrinter.ExcelAccess excel = GetExcel();
excel.Print();
excel.Close();
}
catch (Exception exp)
{
PublicMethod.WriteLog(exp);
}
}
public GoldPrinter.ExcelAccess GetExcel()
{
//调用第三方操作EXCEL打印插件GoldPrinter实现打印
GoldPrinter.ExcelAccess excel = new GoldPrinter.ExcelAccess();
string strExcelTemplateFile = Application.StartupPath;
strExcelTemplateFile += @"\Template\" + strFileName;
excel.Open(strExcelTemplateFile); //调用模板文件
excel.IsVisibledExcel = false;
PublicToDoument.SetExcelValue(panel1, excel);
List<ApplianceRecord> ApplianceRecordList = new List<ApplianceRecord>();
if (instrumentList.ApplianceRecordList != null && instrumentList.ApplianceRecordList.Count > 0)
{
ApplianceRecordList = instrumentList.ApplianceRecordList;
}
else
{
ApplianceRecordList = GetApplianceRecord();
}
#region
#region
string name1 = PublicMethod.GetHospitalName();
Microsoft.Office.Interop.Excel.Range range = excel.GetRange(1, 1, 55, 55);
{ excel.SetCellText(6, "C", this.TxtName.Text.Trim()); }//患者
{ excel.SetCellText(6, "L", this.TxtSex.Text.Trim()); }//性别
{ excel.SetCellText(6, "R", this.TxtAge.Text.Trim()); }//年龄
{ excel.SetCellText(6, "X", this.TxtDepartment.Text.Trim()); }//科室
{ excel.SetCellText(6, "AE", this.txtEndemicArea.Text.Trim()); }//病区
{ excel.SetCellText(6, "AL", this.TxtBed.Text.Trim()); }//床号
{ excel.SetCellText(7, "AE", this.TxtInHospitalNo.Text.Trim()); }//住院号
{ excel.SetCellText(7, "F", this.txtOpeRoom.Text.Trim()); }//手术日期
{ excel.SetCellText(8, "F", this.txtOperation.Text.Trim()); }//实施手术
FileInfo img = new FileInfo(@"C:\temp\" + rangname + ".png");
PublicToDoument.InsertPicture(excel, img, 170, 160);
#endregion
#region
int index = 0;
for (int i = 25; i < 39; i++)
{
if (ApplianceRecordList.Count > 0 && index < ApplianceRecordList.Count)
{
{ excel.SetCellText(i, "A", ApplianceRecordList[index].ApplianceName); }//器械名称
if (ApplianceRecordList[index].OpeFront != null && ApplianceRecordList[index].OpeFront != "" && ApplianceRecordList[index].OpeFront != @"\")
{ excel.SetCellText(i, "F", ApplianceRecordList[index].OpeFront.ToString()); }//术前
//else setLine(excel.GetRange(i, "H"));
if (ApplianceRecordList[index].OpeDoing != null && ApplianceRecordList[index].OpeDoing != "" && ApplianceRecordList[index].OpeDoing != @"\")
{ excel.SetCellText(i, "J", ApplianceRecordList[index].OpeDoing.ToString()); }//术中
//else setLine(excel.GetRange(i, "L"));
if (ApplianceRecordList[index].CloseFront != null && ApplianceRecordList[index].CloseFront != "" && ApplianceRecordList[index].CloseFront != @"\")
{ excel.SetCellText(i, "N", ApplianceRecordList[index].CloseFront.ToString()); }//关闭腔体前
//else setLine(excel.GetRange(i, "P"));
if (ApplianceRecordList[index].CloseLast != null && ApplianceRecordList[index].CloseLast != "" && ApplianceRecordList[index].CloseLast != @"\")
{ excel.SetCellText(i, "R", ApplianceRecordList[index].CloseLast.ToString()); }//关闭腔体后
//else setLine(excel.GetRange(i, "S"));
index++;
continue;
}
{ excel.SetCellText(i, "A", ""); }//器械名称
{ excel.SetCellText(i, "F", ""); }//术前
{ excel.SetCellText(i, "J", ""); }//术中
{ excel.SetCellText(i, "N", ""); }//关闭腔体前
{ excel.SetCellText(i, "R", ""); }//关闭腔体后
}
for (int i = 25; i < 39; i++)
{
if (ApplianceRecordList.Count > 0 && index < ApplianceRecordList.Count)
{
{ excel.SetCellText(i, "V", ApplianceRecordList[index].ApplianceName); }//器械名称
if (ApplianceRecordList[index].OpeFront != null && ApplianceRecordList[index].OpeFront != "" && ApplianceRecordList[index].OpeFront != @"\")
{ excel.SetCellText(i, "AA", ApplianceRecordList[index].OpeFront.ToString()); }//术前
//else setLine(excel.GetRange(i, "AC"));
if (ApplianceRecordList[index].OpeDoing != null && ApplianceRecordList[index].OpeDoing != "" && ApplianceRecordList[index].OpeDoing != @"\")
{ excel.SetCellText(i, "AE", ApplianceRecordList[index].OpeDoing.ToString()); }//术中
//else setLine(excel.GetRange(i, "AG"));
if (ApplianceRecordList[index].CloseFront != null && ApplianceRecordList[index].CloseFront != "" && ApplianceRecordList[index].CloseFront != @"\")
{ excel.SetCellText(i, "AI", ApplianceRecordList[index].CloseFront.ToString()); }//关闭腔体前
//else setLine(excel.GetRange(i, "AK"));
if (ApplianceRecordList[index].CloseLast != null && ApplianceRecordList[index].CloseLast != "" && ApplianceRecordList[index].CloseLast != @"\")
{ excel.SetCellText(i, "AM", ApplianceRecordList[index].CloseLast.ToString()); }//关闭腔体后
//else setLine(excel.GetRange(i, "AN"));
index++;
continue;
}
{ excel.SetCellText(i, "V", ""); }//器械名称
{ excel.SetCellText(i, "AA", ""); }//术前
{ excel.SetCellText(i, "AE", ""); }//术中
{ excel.SetCellText(i, "AI", ""); }//关闭腔体前
{ excel.SetCellText(i, "AM", ""); }//关闭腔体后
}
#endregion
#endregion
return excel;
}
public void toolStripButton3_Click(object sender, EventArgs e)
{
Initial();

View File

@ -2076,7 +2076,7 @@
this.radioButton4.Font = new System.Drawing.Font("微软雅黑", 7.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.radioButton4.Location = new System.Drawing.Point(4, 59);
this.radioButton4.Name = "radioButton4";
this.radioButton4.Size = new System.Drawing.Size(83, 20);
this.radioButton4.Size = new System.Drawing.Size(82, 20);
this.radioButton4.TabIndex = 1435;
this.radioButton4.TabStop = true;
this.radioButton4.Text = "V 静脉穿刺";
@ -2089,7 +2089,7 @@
this.radioButton5.Font = new System.Drawing.Font("微软雅黑", 7.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.radioButton5.Location = new System.Drawing.Point(4, 102);
this.radioButton5.Name = "radioButton5";
this.radioButton5.Size = new System.Drawing.Size(73, 20);
this.radioButton5.Size = new System.Drawing.Size(72, 20);
this.radioButton5.TabIndex = 1435;
this.radioButton5.TabStop = true;
this.radioButton5.Text = "⊙ 引流管";
@ -2102,7 +2102,7 @@
this.radioButton3.Font = new System.Drawing.Font("微软雅黑", 7.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.radioButton3.Location = new System.Drawing.Point(4, 81);
this.radioButton3.Name = "radioButton3";
this.radioButton3.Size = new System.Drawing.Size(84, 20);
this.radioButton3.Size = new System.Drawing.Size(83, 20);
this.radioButton3.TabIndex = 1435;
this.radioButton3.TabStop = true;
this.radioButton3.Text = "A 动脉穿刺";
@ -2115,7 +2115,7 @@
this.radioButton2.Font = new System.Drawing.Font("微软雅黑", 7.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.radioButton2.Location = new System.Drawing.Point(4, 21);
this.radioButton2.Name = "radioButton2";
this.radioButton2.Size = new System.Drawing.Size(107, 20);
this.radioButton2.Size = new System.Drawing.Size(106, 20);
this.radioButton2.TabIndex = 1435;
this.radioButton2.TabStop = true;
this.radioButton2.Text = "▬ 贴负极板部位";
@ -2128,7 +2128,7 @@
this.label19.Font = new System.Drawing.Font("微软雅黑", 7.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label19.Location = new System.Drawing.Point(4, 41);
this.label19.Name = "label19";
this.label19.Size = new System.Drawing.Size(63, 16);
this.label19.Size = new System.Drawing.Size(62, 16);
this.label19.TabIndex = 1438;
this.label19.Text = "穿刺部位:";
//
@ -2138,7 +2138,7 @@
this.radioButton1.Font = new System.Drawing.Font("微软雅黑", 7.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.radioButton1.Location = new System.Drawing.Point(4, 0);
this.radioButton1.Name = "radioButton1";
this.radioButton1.Size = new System.Drawing.Size(84, 20);
this.radioButton1.Size = new System.Drawing.Size(83, 20);
this.radioButton1.TabIndex = 1435;
this.radioButton1.TabStop = true;
this.radioButton1.Text = "卅 切口部位";

View File

@ -121,7 +121,7 @@
<data name="pictureBox1.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAAJYAAACICAIAAACKv4VeAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAS
dAAAEnQB3mYfeAAAIcVJREFUeF7tnXlUFecZxsnpkpOe2lib9hzbmMa2mpNooiUY0ciiuKEpEUUjBhSj
cgAAEnIBXmVb4wAAIcVJREFUeF7tnXlUFecZxsnpkpOe2lib9hzbmMa2mpNooiUY0ciiuKEpEUUjBhSj
uAKCEiMuuGCVuBuViEtxzYJGI1GUoLjVkBAVFa1RJApqYoDELUiMNe2vdz5uhtnuNhe5PT5/cO47wL0z
87zL837fN9/1+s99eDjuU+jxuE+hx+M+hR6POqLw9u3bJ06cOHLkSFFR0d27d8XR+zADbqdwz549fn5+
jRo1+tOf/vTkk0/y87e//W3z5s3z8/PFX/wf4d///vf58+fPnj27bdu2pUuX5uTklJSUfP/99+LX7oEb

View File

@ -218,7 +218,11 @@ namespace AIMS.OperationDoing.AnasRecordBill
dtpOperatorTime.Value = DateTime.Parse(DateTime.Parse(dgvInstrument.SelectedRows[0].Cells["OperatorTime"].Value.ToString()).ToString("yyyy-MM-dd 00:00:00"));
txtRemark.Text = dgvInstrument.SelectedRows[0].Cells["Remark"].Value.ToString();
cboClean.Text = dgvInstrument.SelectedRows[0].Cells["IsClean"].Value.ToString();
}
}
private void tspPrint_Click(object sender, EventArgs e)
{
}
}
}

View File

@ -29,16 +29,16 @@
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(frmInstrumentRegistration));
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle5 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle6 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle7 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle8 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle9 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle10 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle11 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle14 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle15 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle12 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle13 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle16 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle17 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle18 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle19 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle20 = new System.Windows.Forms.DataGridViewCellStyle();
this.tsbSave = new System.Windows.Forms.ToolStripButton();
this.toolStripSeparator1 = new System.Windows.Forms.ToolStripSeparator();
this.tsbExit = new System.Windows.Forms.ToolStripButton();
@ -169,6 +169,8 @@
this.tspPrint.Name = "tspPrint";
this.tspPrint.Size = new System.Drawing.Size(76, 25);
this.tspPrint.Text = " 打印 ";
this.tspPrint.Visible = false;
this.tspPrint.Click += new System.EventHandler(this.tspPrint_Click);
//
// dgvInstrumentType
//
@ -176,34 +178,34 @@
this.dgvInstrumentType.AllowUserToDeleteRows = false;
this.dgvInstrumentType.BackgroundColor = System.Drawing.Color.White;
this.dgvInstrumentType.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
dataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Control;
dataGridViewCellStyle1.Font = new System.Drawing.Font("微软雅黑", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
dataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.WindowText;
dataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
this.dgvInstrumentType.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle1;
dataGridViewCellStyle11.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
dataGridViewCellStyle11.BackColor = System.Drawing.SystemColors.Control;
dataGridViewCellStyle11.Font = new System.Drawing.Font("微软雅黑", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
dataGridViewCellStyle11.ForeColor = System.Drawing.SystemColors.WindowText;
dataGridViewCellStyle11.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle11.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle11.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
this.dgvInstrumentType.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle11;
this.dgvInstrumentType.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.dgvInstrumentType.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.IRName,
this.IRNumber});
dataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
dataGridViewCellStyle4.BackColor = System.Drawing.SystemColors.Window;
dataGridViewCellStyle4.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
dataGridViewCellStyle4.ForeColor = System.Drawing.SystemColors.ControlText;
dataGridViewCellStyle4.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle4.SelectionForeColor = System.Drawing.SystemColors.ControlText;
dataGridViewCellStyle4.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dgvInstrumentType.DefaultCellStyle = dataGridViewCellStyle4;
dataGridViewCellStyle14.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
dataGridViewCellStyle14.BackColor = System.Drawing.SystemColors.Window;
dataGridViewCellStyle14.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
dataGridViewCellStyle14.ForeColor = System.Drawing.SystemColors.ControlText;
dataGridViewCellStyle14.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle14.SelectionForeColor = System.Drawing.SystemColors.ControlText;
dataGridViewCellStyle14.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dgvInstrumentType.DefaultCellStyle = dataGridViewCellStyle14;
this.dgvInstrumentType.Dock = System.Windows.Forms.DockStyle.Left;
this.dgvInstrumentType.EnableHeadersVisualStyles = false;
this.dgvInstrumentType.GridColor = System.Drawing.Color.FromArgb(((int)(((byte)(208)))), ((int)(((byte)(215)))), ((int)(((byte)(229)))));
this.dgvInstrumentType.Location = new System.Drawing.Point(0, 28);
this.dgvInstrumentType.Name = "dgvInstrumentType";
this.dgvInstrumentType.RowHeadersVisible = false;
dataGridViewCellStyle5.Font = new System.Drawing.Font("微软雅黑", 10F);
this.dgvInstrumentType.RowsDefaultCellStyle = dataGridViewCellStyle5;
dataGridViewCellStyle15.Font = new System.Drawing.Font("微软雅黑", 10F);
this.dgvInstrumentType.RowsDefaultCellStyle = dataGridViewCellStyle15;
this.dgvInstrumentType.RowTemplate.Height = 23;
this.dgvInstrumentType.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
this.dgvInstrumentType.Size = new System.Drawing.Size(264, 559);
@ -214,8 +216,8 @@
//
this.IRName.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
this.IRName.DataPropertyName = "Name";
dataGridViewCellStyle2.Font = new System.Drawing.Font("微软雅黑", 10F);
this.IRName.DefaultCellStyle = dataGridViewCellStyle2;
dataGridViewCellStyle12.Font = new System.Drawing.Font("微软雅黑", 10F);
this.IRName.DefaultCellStyle = dataGridViewCellStyle12;
this.IRName.HeaderText = "设备仪器名称";
this.IRName.Name = "IRName";
//
@ -223,8 +225,8 @@
//
this.IRNumber.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
this.IRNumber.DataPropertyName = "Numbers";
dataGridViewCellStyle3.Font = new System.Drawing.Font("微软雅黑", 10F);
this.IRNumber.DefaultCellStyle = dataGridViewCellStyle3;
dataGridViewCellStyle13.Font = new System.Drawing.Font("微软雅黑", 10F);
this.IRNumber.DefaultCellStyle = dataGridViewCellStyle13;
this.IRNumber.HeaderText = "设备编号";
this.IRNumber.Name = "IRNumber";
//
@ -232,18 +234,18 @@
//
this.dgvInstrument.AllowUserToAddRows = false;
this.dgvInstrument.AllowUserToDeleteRows = false;
dataGridViewCellStyle6.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(237)))), ((int)(((byte)(249)))), ((int)(((byte)(255)))));
this.dgvInstrument.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle6;
dataGridViewCellStyle16.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(237)))), ((int)(((byte)(249)))), ((int)(((byte)(255)))));
this.dgvInstrument.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle16;
this.dgvInstrument.BackgroundColor = System.Drawing.Color.Snow;
this.dgvInstrument.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
dataGridViewCellStyle7.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle7.BackColor = System.Drawing.SystemColors.Control;
dataGridViewCellStyle7.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
dataGridViewCellStyle7.ForeColor = System.Drawing.SystemColors.WindowText;
dataGridViewCellStyle7.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle7.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle7.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
this.dgvInstrument.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle7;
dataGridViewCellStyle17.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle17.BackColor = System.Drawing.SystemColors.Control;
dataGridViewCellStyle17.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
dataGridViewCellStyle17.ForeColor = System.Drawing.SystemColors.WindowText;
dataGridViewCellStyle17.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle17.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle17.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
this.dgvInstrument.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle17;
this.dgvInstrument.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.dgvInstrument.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.Id,
@ -256,14 +258,14 @@
this.OperatorName,
this.OperatorTime,
this.Remark});
dataGridViewCellStyle8.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
dataGridViewCellStyle8.BackColor = System.Drawing.SystemColors.Window;
dataGridViewCellStyle8.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
dataGridViewCellStyle8.ForeColor = System.Drawing.SystemColors.ControlText;
dataGridViewCellStyle8.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle8.SelectionForeColor = System.Drawing.SystemColors.ControlText;
dataGridViewCellStyle8.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dgvInstrument.DefaultCellStyle = dataGridViewCellStyle8;
dataGridViewCellStyle18.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
dataGridViewCellStyle18.BackColor = System.Drawing.SystemColors.Window;
dataGridViewCellStyle18.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
dataGridViewCellStyle18.ForeColor = System.Drawing.SystemColors.ControlText;
dataGridViewCellStyle18.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle18.SelectionForeColor = System.Drawing.SystemColors.ControlText;
dataGridViewCellStyle18.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dgvInstrument.DefaultCellStyle = dataGridViewCellStyle18;
this.dgvInstrument.Dock = System.Windows.Forms.DockStyle.Fill;
this.dgvInstrument.GridColor = System.Drawing.Color.FromArgb(((int)(((byte)(208)))), ((int)(((byte)(215)))), ((int)(((byte)(229)))));
this.dgvInstrument.Location = new System.Drawing.Point(264, 150);
@ -569,8 +571,8 @@
//
this.dataGridViewTextBoxColumn1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
this.dataGridViewTextBoxColumn1.DataPropertyName = "Id";
dataGridViewCellStyle9.Font = new System.Drawing.Font("微软雅黑", 10F);
this.dataGridViewTextBoxColumn1.DefaultCellStyle = dataGridViewCellStyle9;
dataGridViewCellStyle19.Font = new System.Drawing.Font("微软雅黑", 10F);
this.dataGridViewTextBoxColumn1.DefaultCellStyle = dataGridViewCellStyle19;
this.dataGridViewTextBoxColumn1.HeaderText = "Id";
this.dataGridViewTextBoxColumn1.Name = "dataGridViewTextBoxColumn1";
this.dataGridViewTextBoxColumn1.ReadOnly = true;
@ -580,8 +582,8 @@
//
this.dataGridViewTextBoxColumn2.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
this.dataGridViewTextBoxColumn2.DataPropertyName = "Name";
dataGridViewCellStyle10.Font = new System.Drawing.Font("微软雅黑", 10F);
this.dataGridViewTextBoxColumn2.DefaultCellStyle = dataGridViewCellStyle10;
dataGridViewCellStyle20.Font = new System.Drawing.Font("微软雅黑", 10F);
this.dataGridViewTextBoxColumn2.DefaultCellStyle = dataGridViewCellStyle20;
this.dataGridViewTextBoxColumn2.HeaderText = "名称/型号";
this.dataGridViewTextBoxColumn2.Name = "dataGridViewTextBoxColumn2";
this.dataGridViewTextBoxColumn2.ReadOnly = true;

View File

@ -414,8 +414,7 @@ namespace AIMS.OperationDoing.AnasRecordBill
// excel.Close();
//}
//catch (Exception ex)
//{
// MessageBox.Show("请安装2007版Office,再进行打印!", "系统提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
//{
// PublicMethod.WriteLog(ex, "");
//}
@ -581,8 +580,7 @@ namespace AIMS.OperationDoing.AnasRecordBill
// excel.Close();
// }
// catch (Exception ex)
// {
// MessageBox.Show("请安装2007版Office,再进行打印!", "系统提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
// {
// PublicMethod.WriteLog(ex, "");
// }

View File

@ -1640,7 +1640,7 @@ namespace AIMS.OperationFront.UI
GoldPrinter.ExcelAccess excel = new GoldPrinter.ExcelAccess();
excel.IsVisibledExcel = false;
string filepath = string.Format("{0}\\printTemplate\\职工出缺勤表.xlt", Application.StartupPath);
string filepath = string.Format("{0}\\Template\\职工出缺勤表.xlt", Application.StartupPath);
excel.Open(filepath);
Microsoft.Office.Interop.Excel.Worksheet xlSheet = (Microsoft.Office.Interop.Excel.Worksheet)excel.Workbooks.ActiveSheet;
string strTitle = "职工出(缺)勤表";

View File

@ -850,7 +850,7 @@ namespace AIMS.OperationFront.UI
GoldPrinter.ExcelAccess excel = new GoldPrinter.ExcelAccess();
excel.IsVisibledExcel = false;
string filepath = string.Format("{0}\\printTemplate\\职工出缺勤表.xlt", System.Windows.Forms.Application.StartupPath);
string filepath = string.Format("{0}\\Template\\职工出缺勤表.xlt", System.Windows.Forms.Application.StartupPath);
excel.Open(filepath);
Microsoft.Office.Interop.Excel.Worksheet xlSheet = (Microsoft.Office.Interop.Excel.Worksheet)excel.Workbooks.ActiveSheet;
string strTitle;

View File

@ -153,6 +153,7 @@
this.label3 = new System.Windows.Forms.Label();
this.txtMdrecNo = new System.Windows.Forms.TextBox();
this.label2 = new System.Windows.Forms.Label();
this.rboRJ = new System.Windows.Forms.RadioButton();
this.toolStrip1.SuspendLayout();
this.panel1.SuspendLayout();
this.groupBox3.SuspendLayout();
@ -669,10 +670,11 @@
// panel2
//
this.panel2.Controls.Add(this.rboZQ);
this.panel2.Controls.Add(this.rboRJ);
this.panel2.Controls.Add(this.rboJZ);
this.panel2.Location = new System.Drawing.Point(309, 25);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(124, 26);
this.panel2.Size = new System.Drawing.Size(170, 26);
this.panel2.TabIndex = 31;
//
// rboZQ
@ -703,7 +705,7 @@
//
this.panel3.Controls.Add(this.rdbIsPlanReturnOperation);
this.panel3.Controls.Add(this.rdbIsNotPlanReturnOperation);
this.panel3.Location = new System.Drawing.Point(907, 21);
this.panel3.Location = new System.Drawing.Point(958, 21);
this.panel3.Name = "panel3";
this.panel3.Size = new System.Drawing.Size(148, 26);
this.panel3.TabIndex = 31;
@ -886,7 +888,7 @@
// chbIsReturnOperation
//
this.chbIsReturnOperation.AutoSize = true;
this.chbIsReturnOperation.Location = new System.Drawing.Point(798, 25);
this.chbIsReturnOperation.Location = new System.Drawing.Point(849, 25);
this.chbIsReturnOperation.Name = "chbIsReturnOperation";
this.chbIsReturnOperation.Size = new System.Drawing.Size(96, 18);
this.chbIsReturnOperation.TabIndex = 11;
@ -897,7 +899,7 @@
// btnCurrentTime
//
this.btnCurrentTime.Font = new System.Drawing.Font("微软雅黑", 10F);
this.btnCurrentTime.Location = new System.Drawing.Point(704, 22);
this.btnCurrentTime.Location = new System.Drawing.Point(755, 22);
this.btnCurrentTime.Name = "btnCurrentTime";
this.btnCurrentTime.Size = new System.Drawing.Size(81, 26);
this.btnCurrentTime.TabIndex = 10;
@ -921,7 +923,7 @@
this.dtpOrderOperationTime.CustomFormat = "yyyy-MM-dd HH:mm";
this.dtpOrderOperationTime.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.dtpOrderOperationTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
this.dtpOrderOperationTime.Location = new System.Drawing.Point(538, 24);
this.dtpOrderOperationTime.Location = new System.Drawing.Point(589, 24);
this.dtpOrderOperationTime.Name = "dtpOrderOperationTime";
this.dtpOrderOperationTime.Size = new System.Drawing.Size(153, 23);
this.dtpOrderOperationTime.TabIndex = 9;
@ -959,7 +961,7 @@
//
this.label21.AutoSize = true;
this.label21.ForeColor = System.Drawing.Color.Red;
this.label21.Location = new System.Drawing.Point(434, 29);
this.label21.Location = new System.Drawing.Point(485, 29);
this.label21.Name = "label21";
this.label21.Size = new System.Drawing.Size(91, 14);
this.label21.TabIndex = 8;
@ -1442,6 +1444,18 @@
this.label2.TabIndex = 1;
this.label2.Text = "住 院 号";
//
// rboRJ
//
this.rboRJ.AutoSize = true;
this.rboRJ.Location = new System.Drawing.Point(122, 5);
this.rboRJ.Name = "rboRJ";
this.rboRJ.Size = new System.Drawing.Size(53, 18);
this.rboRJ.TabIndex = 13;
this.rboRJ.TabStop = true;
this.rboRJ.Text = "日间";
this.rboRJ.UseVisualStyleBackColor = true;
this.rboRJ.CheckedChanged += new System.EventHandler(this.rboZQ_CheckedChanged);
//
// frmOperationApplyDetail
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
@ -1600,5 +1614,6 @@
private System.Windows.Forms.RadioButton rboJZ;
public System.Windows.Forms.ToolStripButton tsbExit;
public System.Windows.Forms.ToolStripButton tsbCancel;
private System.Windows.Forms.RadioButton rboRJ;
}
}

View File

@ -94,8 +94,10 @@ namespace AIMS.OperationFront.UI
cboApplyDepId.SelectedValue = EditOperationApplyObj.ApplyDepId;
if (EditOperationApplyObj.OperationType == "择期")
rboZQ.Checked = true;
else
if (EditOperationApplyObj.OperationType == "急诊")
rboJZ.Checked = true;
if (EditOperationApplyObj.OperationType == "日间")
rboRJ.Checked = true;
if (EditOperationApplyObj.OrderOperationTime != null)
dtpOrderOperationTime.Value = EditOperationApplyObj.OrderOperationTime.Value;
//txtOperationTimeLeight.Text = EditOperationApplyObj.OperationTimeLeight.ToString();
@ -830,7 +832,7 @@ namespace AIMS.OperationFront.UI
rdbIsNotPlanReturnOperation.Checked = true;
}
}
#endregion
private void tsbExit_Click(object sender, EventArgs e)
@ -902,7 +904,18 @@ namespace AIMS.OperationFront.UI
OperationApplyObj = EditOperationApplyObj;
}
OperationApplyObj.ApplyDepId = int.Parse(cboApplyDepId.SelectedValue.ToString());
OperationApplyObj.OperationType = rboJZ.Checked == true ? "急诊" : "择期";
if ( rboJZ.Checked == true )
{
OperationApplyObj.OperationType = "急诊";
}
if ( rboRJ.Checked == true )
{
OperationApplyObj.OperationType = "日间";
}
if ( rboZQ.Checked == true )
{
OperationApplyObj.OperationType = "择期";
}
OperationApplyObj.OrderOperationTime = DateTime.Parse(dtpOrderOperationTime.Value.ToString("yyyy-MM-dd HH:mm"));
//if (txtOperationTimeLeight.Text != "")
// OperationApplyObj.OperationTimeLeight = int.Parse(txtOperationTimeLeight.Text);
@ -944,7 +957,7 @@ namespace AIMS.OperationFront.UI
BOrisPatient.Add(Oris_PatientObj);
OperationApplyObj.OrisPatientId = BOrisPatient.GetOris_PatientMaxId();
BOperationApply.Add(OperationApplyObj);
SaveSelectItem(BOperationApply.GetOperationApplyMaxId(), OperationApplyObj.OperateDate.Value );
SaveSelectItem(BOperationApply.GetOperationApplyMaxId(), OperationApplyObj.OperateDate.Value);
HelperDB.DbHelperSQL.CommitTrans();
MessageBox.Show("提交成功!", "系统提示");
@ -960,7 +973,7 @@ namespace AIMS.OperationFront.UI
//Oris_PatientObj.Id = BOperationApply.SelectSingle(EditApplyId).Oris_PatientId;
//OperationApplyObj.Id = EditApplyId;
if (OperationApplyObj.PlanOperationTime!=null && OperationApplyObj.PlanOperationTime.Value.Year != 1)
if (OperationApplyObj.PlanOperationTime != null && OperationApplyObj.PlanOperationTime.Value.Year != 1)
if (OperationApplyObj.OrderOperationTime.Value.Day != OperationApplyObj.PlanOperationTime.Value.Day)
{
OperationApplyObj.PlanOperationTime = OperationApplyObj.OrderOperationTime;
@ -1312,9 +1325,9 @@ namespace AIMS.OperationFront.UI
{
MessageBox.Show("申请科室不能为空!");
}
else if (rboZQ.Checked == false && rboJZ.Checked == false)
else if (rboZQ.Checked == false && rboJZ.Checked == false && rboRJ.Checked == false)
{
MessageBox.Show("请选择择期或急诊", "系统提示");
MessageBox.Show("请选择择期或急诊或日间", "系统提示");
}
else if (SelectDiseaseData.Count < 1)
{
@ -1641,7 +1654,7 @@ namespace AIMS.OperationFront.UI
private void rboZQ_CheckedChanged(object sender, EventArgs e)
{
if (rboJZ.Checked == true)
if (rboJZ.Checked == true || rboRJ.Checked == true)
{
dtpOrderOperationTime.Text = DateTime.Now.AddMinutes(1).ToString("yyyy-MM-dd HH:mm");
}

File diff suppressed because it is too large Load Diff

View File

@ -251,7 +251,7 @@
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAD+
CAAAAk1TRnQBSQFMAgEBAgEAAXQBEwF0ARMBEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
CAAAAk1TRnQBSQFMAgEBAgEAAXwBEwF8ARMBEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
AwABQAMAARADAAEBAQABCAYAAQQYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA
AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5
AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA
@ -295,18 +295,12 @@
<metadata name="toolTip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>144, 17</value>
</metadata>
<metadata name="toolTip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>144, 17</value>
</metadata>
<metadata name="ctsThisRoom.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<metadata name="contextMenuStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>360, 17</value>
</metadata>
<metadata name="toolTip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>144, 17</value>
</metadata>
<metadata name="dataGridViewTextBoxColumn3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>

View File

@ -40,12 +40,14 @@
this.buttonX2 = new DevComponents.DotNetBar.ButtonX();
this.buttonX1 = new DevComponents.DotNetBar.ButtonX();
this.label2 = new System.Windows.Forms.Label();
this.lbaCon = new System.Windows.Forms.Label();
this.panel1.SuspendLayout();
this.panel2.SuspendLayout();
this.SuspendLayout();
//
// panel1
//
this.panel1.Controls.Add(this.lbaCon);
this.panel1.Controls.Add(this.label3);
this.panel1.Controls.Add(this.labTabindex);
this.panel1.Controls.Add(this.labelName);
@ -71,10 +73,10 @@
// labTabindex
//
this.labTabindex.Font = new System.Drawing.Font("微软雅黑", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.labTabindex.Location = new System.Drawing.Point(47, 10);
this.labTabindex.Location = new System.Drawing.Point(69, 10);
this.labTabindex.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.labTabindex.Name = "labTabindex";
this.labTabindex.Size = new System.Drawing.Size(125, 20);
this.labTabindex.Size = new System.Drawing.Size(95, 20);
this.labTabindex.TabIndex = 7;
this.labTabindex.Text = "患者1";
this.labTabindex.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
@ -87,13 +89,14 @@
this.labelName.Location = new System.Drawing.Point(0, 10);
this.labelName.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.labelName.Name = "labelName";
this.labelName.Size = new System.Drawing.Size(45, 20);
this.labelName.Size = new System.Drawing.Size(36, 20);
this.labelName.TabIndex = 6;
this.labelName.Text = "急诊";
this.labelName.Click += new System.EventHandler(this.labTabindex_Click);
//
// lblNurse2
//
this.lblNurse2.BackColor = System.Drawing.Color.Transparent;
this.lblNurse2.Dock = System.Windows.Forms.DockStyle.Top;
this.lblNurse2.Font = new System.Drawing.Font("微软雅黑", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblNurse2.Location = new System.Drawing.Point(0, 88);
@ -106,6 +109,7 @@
//
// lblNurse
//
this.lblNurse.BackColor = System.Drawing.Color.Transparent;
this.lblNurse.Dock = System.Windows.Forms.DockStyle.Top;
this.lblNurse.Font = new System.Drawing.Font("微软雅黑", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblNurse.Location = new System.Drawing.Point(0, 71);
@ -118,6 +122,7 @@
//
// lblAnesDoctors
//
this.lblAnesDoctors.BackColor = System.Drawing.Color.Transparent;
this.lblAnesDoctors.Dock = System.Windows.Forms.DockStyle.Top;
this.lblAnesDoctors.Font = new System.Drawing.Font("微软雅黑", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblAnesDoctors.Location = new System.Drawing.Point(0, 54);
@ -130,6 +135,7 @@
//
// lblOpeDoctors
//
this.lblOpeDoctors.BackColor = System.Drawing.Color.Transparent;
this.lblOpeDoctors.Dock = System.Windows.Forms.DockStyle.Top;
this.lblOpeDoctors.Font = new System.Drawing.Font("微软雅黑", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblOpeDoctors.Location = new System.Drawing.Point(0, 37);
@ -188,6 +194,18 @@
this.label2.Text = "状态:手术中";
this.label2.Click += new System.EventHandler(this.labTabindex_Click);
//
// lbaCon
//
this.lbaCon.Font = new System.Drawing.Font("微软雅黑", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lbaCon.ForeColor = System.Drawing.Color.Purple;
this.lbaCon.Location = new System.Drawing.Point(40, 10);
this.lbaCon.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.lbaCon.Name = "lbaCon";
this.lbaCon.Size = new System.Drawing.Size(36, 20);
this.lbaCon.TabIndex = 8;
this.lbaCon.Text = "感染";
this.lbaCon.Visible = false;
//
// ucPatientCard
//
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
@ -220,5 +238,6 @@
public System.Windows.Forms.Label label3;
public DevComponents.DotNetBar.ButtonX buttonX2;
public DevComponents.DotNetBar.ButtonX buttonX1;
public System.Windows.Forms.Label lbaCon;
}
}

View File

@ -35,7 +35,8 @@ namespace AIMS.OremrUserControl
public ucPatientCard(DataRow dr)
{
InitializeComponent();
this.BindWaterMark(dr["OperationRoom"].ToString());
this.BindWaterMark2(dr["OperationRoom"].ToString(), 150, 55, Color.DarkGray);
//this.BindWaterMark(dr["OperationRoom"].ToString());
this.Tag = dr["OperationRoomId"].ToString();
_dr = dr;
RecorId = int.Parse(dr["Id"].ToString());
@ -48,6 +49,11 @@ namespace AIMS.OremrUserControl
lblAnesDoctors.Text = "麻醉医生:" + dr["AnesthesiaDoctor"].ToString();
lblNurse.Text = "洗手护士:" + dr["InstrumentNurse"].ToString();
lblNurse2.Text = "巡回护士:" + dr["TourNurse"].ToString();
if (dr["Contagion"] != null && dr["Contagion"].ToString() != "" && dr["Contagion"].ToString() != "无" && dr["Contagion"].ToString() != "未报")
{
lbaCon.Text = dr["Contagion"].ToString();
lbaCon.Visible = true;
}
if (!labelName.Text.Contains("急")) labelName.ForeColor = Color.DarkGreen;
label2.Text = "状态:" + dr["State"].ToString();
if (dr["State"].ToString() == "手术中")

View File

@ -235,6 +235,10 @@ namespace AIMS.OremrUserControl
{
grNew.CellStyles.Default.Background.Color1 = Color.Purple;
}
else if (item["OperationType"].ToString() == "日间")
{
grNew.CellStyles.Default.Background.Color1 = Color.DeepSkyBlue;
}
else if (item["OperationType"].ToString() == "急诊")
{
grNew.CellStyles.Default.Background.Color1 = Color.Red;

Binary file not shown.

Before

Width:  |  Height:  |  Size: 602 B

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 695 B

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 602 B

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 695 B

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 878 B

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 878 B

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 KiB

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 910 B

After

Width:  |  Height:  |  Size: 3.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 910 B

After

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 910 B

After

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 910 B

After

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -30,10 +30,9 @@ namespace AIMSBLL
_record.OperationBeginTime = titleTime.OperationBeginTime;
_record.OperationEndTime = titleTime.OperationEndTime;
_record.OutRoomTime = titleTime.OutRoomTime;
_record.SpareFive = "";
if (titleTime.OutRoomTime != null && titleTime.InRoomTime != null)
_record.SpareFive = Convert.ToInt32(((TimeSpan)(titleTime.OutRoomTime - titleTime.InRoomTime)).TotalMinutes).ToString() + "分钟";
else
_record.SpareFive = "";
DataTable OperationFrontdt = BOperationApply.GetOperationFrontDataTableByPatientId(PatientId);
if (OperationFrontdt.Rows.Count > 0)
@ -94,6 +93,37 @@ namespace AIMSBLL
_record.OpeRecordInfo = BOperationRecordInfo.SelectSingle("OperationRecordId=" + _record.Id, null);
if (_record.OpeRecordInfo == null) _record.OpeRecordInfo = new OperationRecordInfo();
_record.SpareSix = "";
if (_record.OpeRecordInfo.AnesthesiaSucceed != null && _record.OpeRecordInfo.AnesthesiaSucceed != "")
{
_record.SpareSix += "麻醉接台:" + _record.OpeRecordInfo.AnesthesiaSucceed + " ";
if (_record.OpeRecordInfo.AnesthesiaSucceedTime != null)
_record.SpareSix += "时间:" + _record.OpeRecordInfo.AnesthesiaSucceedTime.Value.ToString("yyyy-MM-dd HH:mm") + " ";
}
if (_record.OpeRecordInfo.InstrumentNurseSucceed != null && _record.OpeRecordInfo.InstrumentNurseSucceed != "")
{
_record.SpareSix += "巡回接台:" + _record.OpeRecordInfo.InstrumentNurseSucceed + " ";
if (_record.OpeRecordInfo.InstrumentNurseSucceedTime != null)
_record.SpareSix += "时间:" + _record.OpeRecordInfo.InstrumentNurseSucceedTime.Value.ToString("yyyy-MM-dd HH:mm") + " ";
}
if (_record.OpeRecordInfo.TourNurseSucceed != null && _record.OpeRecordInfo.TourNurseSucceed != "")
{
_record.SpareSix += "器械接台:" + _record.OpeRecordInfo.TourNurseSucceed + " ";
if (_record.OpeRecordInfo.TourNurseSucceedTime != null)
_record.SpareSix += "时间:" + _record.OpeRecordInfo.TourNurseSucceedTime.Value.ToString("yyyy-MM-dd HH:mm") + " ";
}
if (_record.OpeRecordInfo.Experts != null && _record.OpeRecordInfo.Experts != "")
{
_record.SpareSix += "外请专家:" + _record.OpeRecordInfo.Experts + " ";
}
if (_record.OpeRecordInfo.RuleAnesthesiaDoctor != null && _record.OpeRecordInfo.RuleAnesthesiaDoctor != "")
{
_record.SpareSix += "规培麻醉医生:" + _record.OpeRecordInfo.RuleAnesthesiaDoctor + " ";
}
if (_record.OpeRecordInfo.RuleNurse != null && _record.OpeRecordInfo.RuleNurse != "")
{
_record.SpareSix += "规培护士:" + _record.OpeRecordInfo.RuleNurse + " ";
}
_record.OpeRecoverInInfo = BOperationRecoverInInfo.SelectSingle("PatientId=" + _record.PatientId, null);
if (_record.OpeRecoverInInfo == null) _record.OpeRecoverInInfo = new OperationRecoverInInfo();
@ -107,6 +137,7 @@ namespace AIMSBLL
item.FactBloodGasAnalysisDataList = BFactBloodGasAnalysisData.Select("RecordId=" + item.Id, null);
}
int x = 0;
double allDrugDose = 0, allOutDose = 0;
_record.SpareTwo = "";

View File

@ -24,7 +24,7 @@ namespace AIMSBLL
{
string strSql = "SELECT of1.ApplyId Id, of1.PatientId, of1.ApplyId, of1.ApplyDepName, of1.OperationType, of1.MdrecNo, of1.PatientName, " +
"of1.ApplyOperationInfoName, of1.OperationDoctor, " +
"of1.AnesthesiaDoctor,of1.OperationRoomId , of1.State ,of1.Sex,[dbo].[funGetAge](of1.BirthDay,getdate()) age,of1.PlanOperationTime,of1.InstrumentNurse,of1.TourNurse,of1.ApplyDiagnoseInfoName,of1.OperationRoom " +
"of1.AnesthesiaDoctor,of1.OperationRoomId , of1.State ,of1.Sex,[dbo].[funGetAge](of1.BirthDay,getdate()) age,of1.PlanOperationTime,of1.InstrumentNurse,of1.TourNurse,of1.ApplyDiagnoseInfoName,of1.OperationRoom ,of1.Contagion " +
"FROM V_OperationFront of1 WHERE of1.State in('已审核','预排程','已排程','已访视') and of1.OrderOperationTime>='" + BeginDate + "' AND of1.OrderOperationTime<'" + BeginDate.AddDays(1) + "'";
if (Room != "" && Room != "-1") strSql += " and of1.OperationRoomId='" + Room + "'";
return HelperDB.DbHelperSQL.GetDataTable(strSql.ToString());
@ -37,14 +37,14 @@ namespace AIMSBLL
}
public static DataTable GetRelieveLockingPatientDataTable(DateTime BeginDate, string Room)
{
string strSql = "SELECT of2.Id,of1.PatientId, of1.ApplyId, of1.ApplyDepName, of1.OperationType, of1.MdrecNo, of1.PatientName, of2.OperationInfoNames ApplyOperationInfoName, of2.OperationDoctor, of2.AnesthesiaDoctor,of2.OperationRoomId,of2.State ,of1.Sex,[dbo].[funGetAge](of1.BirthDay,getdate()) age,of2.InRoomTime PlanOperationTime,of2.Nurse InstrumentNurse,of2.Nurse2 TourNurse,of2.DiagnoseInfoName ApplyDiagnoseInfoName ,of2.OperationRoom FROM V_OperationDoing of2 left join[dbo].[V_OperationFront] of1 on of1.PatientId = of2.PatientId WHERE of2.State in( '手术中','手术结束') and of2.InRoomTime >= '" + BeginDate + "' AND of2.InRoomTime<'" + BeginDate.AddDays(1) + "' and RecoverId=1";
string strSql = "SELECT of2.Id,of1.PatientId, of1.ApplyId, of1.ApplyDepName, of1.OperationType, of1.MdrecNo, of1.PatientName, of2.OperationInfoNames ApplyOperationInfoName, of2.OperationDoctor, of2.AnesthesiaDoctor,of2.OperationRoomId,of2.State ,of1.Sex,[dbo].[funGetAge](of1.BirthDay,getdate()) age,of2.InRoomTime PlanOperationTime,of2.Nurse InstrumentNurse,of2.Nurse2 TourNurse,of2.DiagnoseInfoName ApplyDiagnoseInfoName ,of2.OperationRoom ,of1.Contagion FROM V_OperationDoing of2 left join[dbo].[V_OperationFront] of1 on of1.PatientId = of2.PatientId WHERE of2.State in( '手术中','手术结束') and of2.InRoomTime >= '" + BeginDate + "' AND of2.InRoomTime<'" + BeginDate.AddDays(1) + "' and RecoverId=1";
if (Room != "" && Room != "-1") strSql += " and of1.OperationRoomId='" + Room + "'";
strSql += " order by [StateId] asc";
return HelperDB.DbHelperSQL.GetDataTable(strSql.ToString());
}
public static DataTable GetRecoverPatientDataTable(DateTime BeginDate)
{
string strSql = "SELECT of2.Id,of1.PatientId, of1.ApplyId, of1.ApplyDepName, of1.OperationType, of1.MdrecNo, of1.PatientName, of2.OperationInfoNames ApplyOperationInfoName, of2.OperationDoctor, of2.AnesthesiaDoctor,of2.OperationRoomId,of2.State ,of1.Sex,[dbo].[funGetAge](of1.BirthDay,getdate()) age,of2.OutRoomTime ,of2.Nurse InstrumentNurse,of2.Nurse2 TourNurse,of2.DiagnoseInfoName ApplyDiagnoseInfoName ,of2.OperationRoom FROM V_OperationDoing of2 left join[dbo].[V_OperationFront] of1 on of1.PatientId = of2.PatientId WHERE of1.State in( '手术结束') and of2.OutRoomTime >= '" + BeginDate + "' AND of2.OutRoomTime<'" + BeginDate.AddDays(1) + "' and RecoverId=1 and of2.Id not in (select iD from OperationRecord where RecoverId<>1)";
string strSql = "SELECT of2.Id,of1.PatientId, of1.ApplyId, of1.ApplyDepName, of1.OperationType, of1.MdrecNo, of1.PatientName, of2.OperationInfoNames ApplyOperationInfoName, of2.OperationDoctor, of2.AnesthesiaDoctor,of2.OperationRoomId,of2.State ,of1.Sex,[dbo].[funGetAge](of1.BirthDay,getdate()) age,of2.OutRoomTime ,of2.Nurse InstrumentNurse,of2.Nurse2 TourNurse,of2.DiagnoseInfoName ApplyDiagnoseInfoName ,of2.OperationRoom,of2.Whereabouts FROM V_OperationDoing of2 left join[dbo].[V_OperationFront] of1 on of1.PatientId = of2.PatientId WHERE of1.State in( '手术结束') and of2.Whereabouts='恢复室' and of2.OutRoomTime >= '" + BeginDate + "' AND of2.OutRoomTime<'" + BeginDate.AddDays(1) + "' and RecoverId=1 and of2.Id not in (select iD from OperationRecord where RecoverId<>1)";
return HelperDB.DbHelperSQL.GetDataTable(strSql.ToString());
}
public static DataTable GetRecoverPatientOutDataTable(DateTime BeginDate)

View File

@ -35,6 +35,11 @@
<SpecificVersion>False</SpecificVersion>
<HintPath>..\AIMS\Extensions\DevComponents.DotNetBar2.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Office.Interop.Excel, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<EmbedInteropTypes>False</EmbedInteropTypes>
<HintPath>..\AIMS\Extensions\Microsoft.Office.Interop.Excel.dll</HintPath>
</Reference>
<Reference Include="Oracle.ManagedDataAccess">
<HintPath>..\AIMS\Extensions\Oracle.ManagedDataAccess.dll</HintPath>
</Reference>
@ -62,6 +67,58 @@
<Compile Include="EditState.cs" />
<Compile Include="ErrorInfo.cs" />
<Compile Include="FTPTransmission.cs" />
<Compile Include="GoldPrinter.ExcelConstants\BordersEdge.cs" />
<Compile Include="GoldPrinter.ExcelConstants\BordersLineStyle.cs" />
<Compile Include="GoldPrinter.ExcelConstants\BordersWeight.cs" />
<Compile Include="GoldPrinter\AlignFlag.cs" />
<Compile Include="GoldPrinter\Body.cs" />
<Compile Include="GoldPrinter\BordersEdgeFlag.cs" />
<Compile Include="GoldPrinter\Bottom.cs" />
<Compile Include="GoldPrinter\Caption.cs" />
<Compile Include="GoldPrinter\CellRectangle.cs" />
<Compile Include="GoldPrinter\ChineseNum.cs" />
<Compile Include="GoldPrinter\DataGridViewListViewHelper.cs" />
<Compile Include="GoldPrinter\DrawBase.cs" />
<Compile Include="GoldPrinter\DrawGrid.cs" />
<Compile Include="GoldPrinter\DrawRectangle.cs" />
<Compile Include="GoldPrinter\DrawText.cs" />
<Compile Include="GoldPrinter\ExcelAccess.cs" />
<Compile Include="GoldPrinter\ExcelBase.cs" />
<Compile Include="GoldPrinter\ExceptionExcelCreateInstance.cs" />
<Compile Include="GoldPrinter\ExceptionExcelOpen.cs" />
<Compile Include="GoldPrinter\ExceptionInvalidPrinter.cs" />
<Compile Include="GoldPrinter\Footer.cs" />
<Compile Include="GoldPrinter\GoldGrid.cs" />
<Compile Include="GoldPrinter\GridBase.cs" />
<Compile Include="GoldPrinter\GridBorderFlag.cs" />
<Compile Include="GoldPrinter\GridLineFlag.cs" />
<Compile Include="GoldPrinter\GridMergeFlag.cs" />
<Compile Include="GoldPrinter\HAlignFlag.cs" />
<Compile Include="GoldPrinter\Header.cs" />
<Compile Include="GoldPrinter\IDraw.cs" />
<Compile Include="GoldPrinter\IGrid.cs" />
<Compile Include="GoldPrinter\ImportExcelArgs.cs" />
<Compile Include="GoldPrinter\ImportExcelDelegate.cs" />
<Compile Include="GoldPrinter\IPrinterPageSetting.cs" />
<Compile Include="GoldPrinter\MisGoldPrinter.cs" />
<Compile Include="GoldPrinter\MultiHeader.cs" />
<Compile Include="GoldPrinter\Outer.cs" />
<Compile Include="GoldPrinter\Printer.cs" />
<Compile Include="GoldPrinter\PrinterBase.cs" />
<Compile Include="GoldPrinter\PrinterMargins.cs" />
<Compile Include="GoldPrinter\PrinterPageSetting.cs" />
<Compile Include="GoldPrinter\PrinterSingleton.cs" />
<Compile Include="GoldPrinter\PrinterTabStops.cs" />
<Compile Include="GoldPrinter\PrintModeFlag.cs" />
<Compile Include="GoldPrinter\PrintPageDelegate.cs" />
<Compile Include="GoldPrinter\Sewing.cs" />
<Compile Include="GoldPrinter\SewingDirectionFlag.cs" />
<Compile Include="GoldPrinter\TimeDef.cs" />
<Compile Include="GoldPrinter\Title.cs" />
<Compile Include="GoldPrinter\Top.cs" />
<Compile Include="GoldPrinter\VAlignFlag.cs" />
<Compile Include="GoldPrinter\WebPrinterPageSetting.cs" />
<Compile Include="GoldPrinter\WinPrinterPageSetting.cs" />
<Compile Include="GPDBConn.cs" />
<Compile Include="GPDbHelper.cs" />
<Compile Include="GPFunctions.cs" />

View File

@ -0,0 +1,17 @@
using System;
namespace GoldPrinter.ExcelConstants
{
public enum BordersEdge
{
xlLineStyleNone,
xlLeft,
xlRight,
xlTop,
xlBottom,
xlDiagonalDown,
xlDiagonalUp,
xlInsideHorizontal,
xlInsideVertical
}
}

View File

@ -0,0 +1,16 @@
using System;
namespace GoldPrinter.ExcelConstants
{
public enum BordersLineStyle
{
xlContinuous,
xlDash,
xlDashDot,
xlDashDotDot,
xlDot,
xlDouble,
xlLineStyleNone,
xlSlantDashDot
}
}

View File

@ -0,0 +1,12 @@
using System;
namespace GoldPrinter.ExcelConstants
{
public enum BordersWeight
{
xlHairline,
xlMedium,
xlThick,
xlThin
}
}

View File

@ -0,0 +1,11 @@
using System;
namespace GoldPrinter
{
public enum AlignFlag
{
Left,
Center,
Right
}
}

View File

@ -0,0 +1,62 @@
using System;
using System.Drawing;
namespace GoldPrinter
{
public class Body : Outer
{
public string[,] GridText
{
get
{
return this.mdrawGrid.GridText;
}
set
{
this.mblnHadInitialized = true;
this.mdrawGrid.GridText = value;
}
}
public string ColsAlignString
{
get
{
return this.mdrawGrid.ColsAlignString;
}
set
{
this.mdrawGrid.ColsAlignString = value;
}
}
public override Font Font
{
get
{
return this.mdrawGrid.Font;
}
set
{
this.mdrawGrid.Font = value;
}
}
public Body()
{
this.IsDrawAllPage = false;
this.mdrawGrid.AlignMent = AlignFlag.Left;
this.mdrawGrid.Border = GridBorderFlag.Single;
this.mdrawGrid.Line = GridLineFlag.Both;
base.IsAverageColsWidth = false;
this.mdrawGrid.Merge = GridMergeFlag.None;
this.mdrawGrid.Font = new Font("宋体", 12f);
this.mdrawGrid.PreferredRowHeight = this.mdrawGrid.Font.Height + 2;
}
public Body(int rows, int cols) : this()
{
base.Initialize(rows, cols);
}
}
}

View File

@ -0,0 +1,15 @@
using System;
namespace GoldPrinter
{
public enum BordersEdgeFlag
{
FourEdge,
Left,
Right,
Top,
Bottom,
DiagonalDown,
DiagonalUp
}
}

View File

@ -0,0 +1,12 @@
using System;
namespace GoldPrinter
{
public class Bottom : Top
{
public Bottom()
{
this.IsDrawAllPage = true;
}
}
}

View File

@ -0,0 +1,112 @@
using System;
using System.Drawing;
namespace GoldPrinter
{
public class Caption : Printer
{
private string _text;
private int _maxRows;
private bool _hasborder;
public string Text
{
get
{
return this._text;
}
set
{
this._text = value;
}
}
public bool HasBorder
{
get
{
return this._hasborder;
}
set
{
this._hasborder = value;
}
}
public int MaxRows
{
get
{
return this._maxRows;
}
set
{
this._maxRows = value;
}
}
public Caption()
{
this._text = "";
this._maxRows = 1;
this._hasborder = false;
this.Font = new Font("宋体", 13f, FontStyle.Italic);
this.IsDrawAllPage = true;
}
public Caption(string text) : this()
{
this._text = text;
}
public override void Draw()
{
base.Draw();
int num = base.PrinterMargins.X1;
int num2 = base.PrinterMargins.Y1;
num += base.MoveX;
num2 += base.MoveY;
int width = base.PrinterMargins.Width;
int num3 = base.TextHeight(this._text);
if (num3 > base.PrinterMargins.Height)
{
num3 = base.PrinterMargins.Height;
}
if (this._maxRows > 0)
{
if (num3 > this.Font.Height * this._maxRows)
{
num3 = this.Font.Height * this._maxRows;
}
}
Rectangle rectangle = new Rectangle(num, num2, width, num3);
StringFormat stringFormat = new StringFormat();
stringFormat.Alignment = StringAlignment.Center;
stringFormat.LineAlignment = StringAlignment.Center;
rectangle.X = (base.PrinterMargins.Width - base.TextWidth(this.Text)) / 2 + base.PrinterMargins.Left + base.MoveX;
rectangle.Y = num2;
if (base.TextWidth(this.Text) < base.PrinterMargins.Width)
{
rectangle.Width = base.TextWidth(this.Text);
}
else
{
rectangle.Width = base.PrinterMargins.Width;
}
rectangle.Height = num3;
base.Rectangle = rectangle;
if (this._hasborder)
{
base.Graphics.DrawRectangle(base.Pen, base.Rectangle.X, base.Rectangle.Y, base.Rectangle.Width, base.Rectangle.Height);
}
rectangle.X--;
rectangle.Y--;
rectangle.Width += 2;
rectangle.Height += 2;
base.Graphics.DrawString(this._text, this.Font, base.Brush, rectangle, stringFormat);
this.Height = num3;
}
}
}

View File

@ -0,0 +1,71 @@
using System;
namespace GoldPrinter
{
public struct CellRectangle
{
private int _cellLeft;
private int _cellTop;
private int _cellWidth;
private int _cellHeight;
public int Left
{
get
{
return this._cellLeft;
}
set
{
this._cellLeft = value;
}
}
public int Top
{
get
{
return this._cellTop;
}
set
{
this._cellTop = value;
}
}
public int Width
{
get
{
return this._cellWidth;
}
set
{
this._cellWidth = value;
}
}
public int Height
{
get
{
return this._cellHeight;
}
set
{
this._cellHeight = value;
}
}
public CellRectangle(int cellLeft, int cellTop, int cellWidth, int cellHeight)
{
this._cellLeft = cellLeft;
this._cellTop = cellTop;
this._cellWidth = cellWidth;
this._cellHeight = cellHeight;
}
}
}

View File

@ -0,0 +1,339 @@
using System;
namespace GoldPrinter
{
public class ChineseNum
{
public static string GetChineseNum(string p_num)
{
ChineseNum chineseNum = new ChineseNum();
return chineseNum.NumToChn(p_num);
}
public static string GetUpperMoney(double p_Money)
{
ChineseNum chineseNum = new ChineseNum();
return chineseNum.GetMoneyChinese(p_Money);
}
private char CharToNum(char x)
{
string text = "零一二三四五六七八九";
string text2 = "0123456789";
return text[text2.IndexOf(x)];
}
private string WanStrToInt(string x)
{
string[] array = new string[]
{
"",
"十",
"百",
"千"
};
string text = "";
int i;
for (i = x.Length - 1; i >= 0; i--)
{
if (x[i] == '0')
{
text = this.CharToNum(x[i]) + text;
}
else
{
text = this.CharToNum(x[i]) + array[x.Length - 1 - i] + text;
}
}
while ((i = text.IndexOf("零零")) != -1)
{
text = text.Remove(i, 1);
}
if (text[text.Length - 1] == '零' && text.Length > 1)
{
text = text.Remove(text.Length - 1, 1);
}
if (text.Length >= 2 && text.Substring(0, 2) == "一十")
{
text = text.Remove(0, 1);
}
return text;
}
private string StrToInt(string x)
{
int length = x.Length;
string text;
if (length <= 4)
{
text = this.WanStrToInt(x);
}
else if (length <= 8)
{
text = this.WanStrToInt(x.Substring(0, length - 4)) + "万";
string text2 = this.WanStrToInt(x.Substring(length - 4, 4));
if (text2.IndexOf("千") == -1 && text2 != "")
{
text = text + "零" + text2;
}
else
{
text += text2;
}
}
else
{
text = this.WanStrToInt(x.Substring(0, length - 8)) + "亿";
string text2 = this.WanStrToInt(x.Substring(length - 8, 4));
if (text2.IndexOf("千") == -1 && text2 != "")
{
text = text + "零" + text2;
}
else
{
text += text2;
}
text += "万";
text2 = this.WanStrToInt(x.Substring(length - 4, 4));
if (text2.IndexOf("千") == -1 && text2 != "")
{
text = text + "零" + text2;
}
else
{
text += text2;
}
}
int num;
if ((num = text.IndexOf("零万")) != -1)
{
text = text.Remove(num + 1, 1);
}
while ((num = text.IndexOf("零零")) != -1)
{
text = text.Remove(num, 1);
}
if (text[text.Length - 1] == '零' && text.Length > 1)
{
text = text.Remove(text.Length - 1, 1);
}
return text;
}
private string StrToDouble(string x)
{
string text = "";
for (int i = 0; i < x.Length; i++)
{
text += this.CharToNum(x[i]);
}
return text;
}
private string NumToChn(string x)
{
string result;
if (x.Length == 0)
{
result = "";
}
else
{
string text = "";
if (x[0] == '-')
{
text = "负";
x = x.Remove(0, 1);
}
if (x[0].ToString() == ".")
{
x = "0" + x;
}
if (x[x.Length - 1].ToString() == ".")
{
x = x.Remove(x.Length - 1, 1);
}
if (x.IndexOf(".") > -1)
{
text = text + this.StrToInt(x.Substring(0, x.IndexOf("."))) + "点" + this.StrToDouble(x.Substring(x.IndexOf(".") + 1));
}
else
{
text += this.StrToInt(x);
}
result = text;
}
return result;
}
private string GetMoneyChinese(double Money)
{
string result;
if (Money == 0.0)
{
result = "";
}
else
{
string text = Money.ToString("#0.00");
int num = text.IndexOf(".");
if (num > 0)
{
text = text.Replace(".", "");
}
if (text.Substring(0, 1) == "0")
{
text = text.Remove(0, 1);
}
text = this.NumstrToChinese(text);
if (text.Length == 0)
{
result = "";
}
else
{
if (Money < 0.0)
{
text = "负" + text;
}
text = text.Replace("0", "零");
text = text.Replace("1", "壹");
text = text.Replace("2", "贰");
text = text.Replace("3", "叁");
text = text.Replace("4", "肆");
text = text.Replace("5", "伍");
text = text.Replace("6", "陆");
text = text.Replace("7", "柒");
text = text.Replace("8", "捌");
text = text.Replace("9", "玖");
text = text.Replace("M", "亿");
text = text.Replace("W", "万");
text = text.Replace("S", "仟");
text = text.Replace("H", "佰");
text = text.Replace("T", "拾");
text = text.Replace("Y", "圆");
text = text.Replace("J", "角");
text = text.Replace("F", "分");
if (text.Substring(text.Length - 1, 1) != "分")
{
text += "整";
}
result = text;
}
}
return result;
}
private string NumstrToChinese(string numstr)
{
string[] array = new string[4];
string text = "";
bool flag = false;
array[0] = "";
array[1] = "T";
array[2] = "H";
array[3] = "S";
for (int i = 1; i <= numstr.Length; i++)
{
int num = numstr.Length - i;
string text2 = numstr.Substring(i - 1, 1);
if (text2 != "0" && num > 1)
{
text = text + text2 + array[(num - 2) % 4];
}
if (text2 == "0" && !flag)
{
text += "0";
flag = true;
}
if (num == 14)
{
if (text.Substring(text.Length - 1) == "0")
{
text = text.Substring(0, text.Length - 1) + "W0";
}
else
{
text += "W";
}
}
if (num == 2)
{
if (text.Substring(text.Length - 1, 1) == "0")
{
text = text.Substring(0, text.Length - 1) + "Y0";
}
else
{
text += "Y";
}
}
if (num == 6)
{
if (text.Length > 2)
{
if (text.Substring(text.Length - 2) != "M0")
{
if (text.Substring(text.Length - 1) == "0")
{
text = text.Substring(0, text.Length - 1) + "W0";
}
else
{
text += "W";
}
}
}
else if (text.Substring(text.Length - 1) == "0")
{
text = text.Substring(0, text.Length - 1) + "W0";
}
else
{
text += "W";
}
}
if (num == 10)
{
if (text.Substring(text.Length - 1) == "0")
{
text = text.Substring(0, text.Length - 1) + "M0";
}
else
{
text += "M";
}
}
if (num == 0 && text2 != "0")
{
text = text + text2 + "F";
}
if (num == 1 && text2 != "0")
{
text = text + text2 + "J";
}
if (text2 != "0")
{
flag = false;
}
}
if (text.Substring(0, 1) == "1" && text.Substring(1, 1) == array[1])
{
text = text.Substring(1);
}
if (text.Substring(text.Length - 1, 1) == "0")
{
text = text.Substring(0, text.Length - 1);
}
if (text.Substring(0, 1) == "0")
{
text = text.Substring(1);
}
if (text.Substring(text.Length - 1, 1) == "M" || text.Substring(text.Length - 1, 1) == "W" || text.Substring(text.Length - 1, 1) == "S" || text.Substring(text.Length - 1, 1) == "H" || text.Substring(text.Length - 1, 1) == "T")
{
text += "Y";
}
return text;
}
}
}

View File

@ -0,0 +1,50 @@
using System;
using System.Windows.Forms;
namespace GoldPrinter
{
public class DataGridViewListViewHelper
{
public static int[] GetColsWidth(ListView listView)
{
int count = listView.Columns.Count;
int[] array = new int[count];
for (int i = 0; i < count; i++)
{
array[i] = listView.Columns[i].Width;
}
return array;
}
public static string[,] ToStringArray(ListView listView, bool includeColumnText)
{
int num = listView.Items.Count;
int count = listView.Columns.Count;
if (includeColumnText)
{
num++;
}
string[,] array = new string[num, count];
int i = 0;
if (includeColumnText)
{
for (i = 0; i < count; i++)
{
array[0, i] = listView.Columns[i].Text;
}
i = 1;
}
int num2 = 0;
while (i < num)
{
for (int j = 0; j < count; j++)
{
array[i, j] = listView.Items[num2].SubItems[j].Text;
}
i++;
num2++;
}
return array;
}
}
}

View File

@ -0,0 +1,86 @@
using System;
using System.Drawing;
namespace GoldPrinter
{
public abstract class DrawBase : IDraw, IDisposable
{
private Graphics _graphics;
private Rectangle _rectangle;
private Brush _brush;
private Pen _pen;
public Graphics Graphics
{
get
{
return this._graphics;
}
set
{
this._graphics = value;
}
}
public Rectangle Rectangle
{
get
{
return this._rectangle;
}
set
{
this._rectangle = value;
}
}
public Pen Pen
{
get
{
return this._pen;
}
set
{
if (value != null)
{
this._pen = value;
}
}
}
public Brush Brush
{
get
{
return this._brush;
}
set
{
if (value != null)
{
this._brush = value;
}
}
}
public abstract void Draw();
public DrawBase()
{
this._rectangle = new Rectangle(0, 0, 0, 0);
this._brush = Brushes.Black;
this._pen = new Pen(this._brush);
this._pen = Pens.Black;
}
public virtual void Dispose()
{
this._brush.Dispose();
this._pen.Dispose();
}
}
}

View File

@ -0,0 +1,579 @@
using System;
using System.Drawing;
using System.Windows.Forms;
namespace GoldPrinter
{
public class DrawGrid : GoldGrid, IDraw, IDisposable
{
private Graphics _graphics;
private Rectangle _rectangle;
private Brush _brush;
private Pen _pen;
public Graphics Graphics
{
get
{
return this._graphics;
}
set
{
this._graphics = value;
}
}
public Rectangle Rectangle
{
get
{
return this._rectangle;
}
set
{
this._rectangle = value;
}
}
public Pen Pen
{
get
{
return this._pen;
}
set
{
if (value != null)
{
this._pen = value;
}
}
}
public Brush Brush
{
get
{
return this._brush;
}
set
{
if (value != null)
{
this._brush = value;
}
}
}
public DrawGrid()
{
this._pen = new Pen(Color.Black);
this._brush = Brushes.Black;
}
public DrawGrid(int rows, int cols)
{
base.Initialize(rows, cols);
}
public override void Dispose()
{
base.Dispose();
this._graphics.Dispose();
}
public void DrawGridLine()
{
this.DrawGridLine(this._graphics, this._rectangle, this.Pen, base.GridText, base.PreferredRowHeight, base.ColsWidth, base.Line, base.Border, new PointF(1f, 1f), base.Merge);
}
public void DrawGridText()
{
this.DrawGridText(this._graphics, this._rectangle, this.Brush, base.GridText, base.PreferredRowHeight, base.ColsWidth, base.ColsAlignString, base.Font, new PointF(1f, 1f), base.Merge);
}
public void DrawGridBorder()
{
this.DrawGridBorder(this._graphics, this._rectangle, this.Pen, base.Border);
}
public void Draw()
{
this.DrawGridLine();
this.DrawGridText();
this.DrawGridBorder();
}
protected void DrawGridLine(Graphics g, Rectangle p_rec, Pen p_pen, int p_rows, int p_cols, int p_rowHeight, int[] p_arrColsWidth, GridLineFlag p_gridLineFlag, GridBorderFlag p_gridBorderFlag, PointF p_scaleXY)
{
Rectangle rectangle = new Rectangle(p_rec.X, p_rec.Y, p_rec.Width, p_rec.Height);
this.TransGrid(g, rectangle, p_scaleXY);
if (p_gridLineFlag != GridLineFlag.None)
{
int width = rectangle.Width;
int height = rectangle.Height;
if (p_gridLineFlag == GridLineFlag.Horizontal || p_gridLineFlag == GridLineFlag.Both)
{
int num = rectangle.X;
int num2 = rectangle.Y;
int x = num + width;
for (int i = 1; i < p_rows; i++)
{
num2 += p_rowHeight;
int y = num2;
g.DrawLine(p_pen, num, num2, x, y);
}
}
if (p_gridLineFlag == GridLineFlag.Vertical || p_gridLineFlag == GridLineFlag.Both)
{
int[] array = new int[p_cols];
int num = rectangle.X;
int num2 = rectangle.Y;
int y = num2 + height;
for (int j = 0; j < p_cols - 1; j++)
{
num += p_arrColsWidth[j];
int x = num;
g.DrawLine(p_pen, num, num2, x, y);
}
}
}
if (p_gridBorderFlag != GridBorderFlag.None)
{
this.DrawGridBorder(g, rectangle, p_pen, p_gridBorderFlag);
}
this.ResetTransGrid();
}
protected void DrawGridLine(Graphics g, Rectangle p_rec, Pen p_pen, string[,] arrStrGrid, int p_rowHeight, int[] p_arrColsWidth, GridLineFlag p_gridLineFlag, GridBorderFlag p_gridBorderFlag, PointF p_scaleXY)
{
int length = arrStrGrid.GetLength(0);
int length2 = arrStrGrid.GetLength(1);
this.DrawGridLine(g, p_rec, p_pen, length, length2, p_rowHeight, p_arrColsWidth, p_gridLineFlag, p_gridBorderFlag, p_scaleXY);
}
protected void DrawGridMergeLine(Graphics g, Rectangle p_rec, Pen p_pen, string[,] arrStrGrid, int p_rowHeight, int[] p_arrColsWidth, GridLineFlag p_gridLineFlag, GridBorderFlag p_gridBorderFlag, PointF p_scaleXY, GridMergeFlag gridMergeFlag)
{
Rectangle rectangle = new Rectangle(p_rec.X, p_rec.Y, p_rec.Width, p_rec.Height);
int length = arrStrGrid.GetLength(0);
int length2 = arrStrGrid.GetLength(1);
if (gridMergeFlag == GridMergeFlag.None)
{
this.DrawGridLine(g, rectangle, p_pen, length, length2, p_rowHeight, p_arrColsWidth, p_gridLineFlag, p_gridBorderFlag, p_scaleXY);
}
else if (p_gridLineFlag != GridLineFlag.None)
{
this.TransGrid(g, rectangle, p_scaleXY);
int[] array = new int[length2];
for (int i = 0; i < length; i++)
{
int num = rectangle.X;
int num2 = rectangle.Y;
for (int j = 0; j < length2; j++)
{
int x = num + p_arrColsWidth[j];
num2 = rectangle.Y + p_rowHeight * i;
int num3 = num2;
if (i > 0)
{
if (gridMergeFlag == GridMergeFlag.Any)
{
if (arrStrGrid[i, j] == "" || arrStrGrid[i, j] != arrStrGrid[i - 1, j])
{
g.DrawLine(p_pen, num, num2, x, num3);
}
}
}
if (j > 0)
{
num3 += p_rowHeight;
x = num;
if (gridMergeFlag == GridMergeFlag.Any)
{
if (arrStrGrid[i, j] == "" || arrStrGrid[i, j] != arrStrGrid[i, j - 1])
{
g.DrawLine(p_pen, num, num2, x, num3);
}
}
}
num += p_arrColsWidth[j];
}
}
if (p_gridBorderFlag != GridBorderFlag.None)
{
this.DrawGridBorder(g, rectangle, p_pen, p_gridBorderFlag);
}
this.ResetTransGrid();
}
}
protected void DrawGridText(Graphics g, Rectangle p_rec, Brush p_brush, string[,] arrStrGrid, int p_rowHeight, int[] p_arrColsWidth, string alignment, Font p_font, PointF p_scaleXY)
{
try
{
Rectangle p_rec2 = new Rectangle(p_rec.X, p_rec.Y, p_rec.Width, p_rec.Height);
Font font = p_font;
if (font == null)
{
font = new Font("宋体", 12f);
}
int length = arrStrGrid.GetLength(0);
int length2 = arrStrGrid.GetLength(1);
int[] array = new int[length2];
AlignFlag[] colsAlign = this.GetColsAlign(alignment);
this.TransGrid(g, p_rec2, p_scaleXY);
StringFormat stringFormat = new StringFormat();
stringFormat.LineAlignment = StringAlignment.Center;
stringFormat.FormatFlags = (StringFormatFlags.NoWrap | StringFormatFlags.LineLimit);
for (int i = 0; i < length; i++)
{
int num = p_rec2.X;
int y = p_rec2.Y + p_rowHeight * i;
for (int j = 0; j < length2; j++)
{
int num2 = p_arrColsWidth[j];
Rectangle r = new Rectangle(num, y, num2, p_rowHeight + 4);
stringFormat.Alignment = StringAlignment.Near;
if (colsAlign.Length > j)
{
if (colsAlign[j] == AlignFlag.Center)
{
stringFormat.Alignment = StringAlignment.Center;
}
else if (colsAlign[j] == AlignFlag.Right)
{
stringFormat.Alignment = StringAlignment.Far;
}
}
g.DrawString(arrStrGrid[i, j], font, p_brush, r, stringFormat);
num += num2;
}
}
this.ResetTransGrid();
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
finally
{
}
}
protected void DrawGridMergeText(Graphics g, Rectangle p_rec, Brush p_brush, string[,] arrStrGrid, int p_rowHeight, int[] p_arrColsWidth, string alignment, Font p_font, PointF p_scaleXY, GridMergeFlag gridMergeFlag)
{
if (gridMergeFlag == GridMergeFlag.None)
{
this.DrawGridText(g, p_rec, p_brush, arrStrGrid, p_rowHeight, p_arrColsWidth, alignment, p_font, p_scaleXY);
}
else
{
try
{
Rectangle p_rec2 = new Rectangle(p_rec.X, p_rec.Y, p_rec.Width, p_rec.Height);
Font font = p_font;
if (font == null)
{
font = new Font("宋体", 12f);
}
int length = arrStrGrid.GetLength(0);
int length2 = arrStrGrid.GetLength(1);
int[] array = new int[length2];
AlignFlag[] colsAlign = this.GetColsAlign(alignment);
this.TransGrid(g, p_rec2, p_scaleXY);
StringFormat stringFormat = new StringFormat();
stringFormat.LineAlignment = StringAlignment.Center;
stringFormat.FormatFlags = (StringFormatFlags.NoWrap | StringFormatFlags.LineLimit);
CellRectangle mergeCell = new CellRectangle(p_rec2.X, p_rec2.Y, 0, p_rowHeight);
for (int i = 0; i < length; i++)
{
for (int j = 0; j < length2; j++)
{
mergeCell = this.GetMergeCell(new Point(p_rec2.X, p_rec2.Y), arrStrGrid, p_rowHeight, p_arrColsWidth, i, j);
Rectangle r = new Rectangle(mergeCell.Left, mergeCell.Top, mergeCell.Width, mergeCell.Height + 4);
stringFormat.Alignment = StringAlignment.Near;
if (colsAlign.Length > j)
{
if (colsAlign[j] == AlignFlag.Center)
{
stringFormat.Alignment = StringAlignment.Center;
}
else if (colsAlign[j] == AlignFlag.Right)
{
stringFormat.Alignment = StringAlignment.Far;
}
}
g.DrawString(arrStrGrid[i, j], font, p_brush, r, stringFormat);
}
}
this.ResetTransGrid();
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
finally
{
}
}
}
protected void DrawGridBorder(Graphics g, Rectangle rec, Pen p_pen, GridBorderFlag p_gridBorderFlag)
{
if (p_gridBorderFlag != GridBorderFlag.None)
{
float width = 1f;
int num = 0;
switch (p_gridBorderFlag)
{
case GridBorderFlag.SingleBold:
width = 2f;
break;
case GridBorderFlag.Double:
g.DrawRectangle(p_pen, rec);
num = 2;
break;
case GridBorderFlag.DoubleBold:
g.DrawRectangle(p_pen, rec);
width = 2f;
num = 3;
break;
}
Pen pen = (Pen)p_pen.Clone();
pen.Width = width;
Rectangle rect = rec;
rect.X = rec.X - num;
rect.Y = rec.Y - num;
rect.Width = rec.Width + num * 2;
rect.Height = rec.Height + num * 2;
g.DrawRectangle(pen, rect);
pen.Dispose();
}
}
private void TransGrid(Graphics g, Rectangle p_rec, PointF p_scaleXY)
{
if (!p_scaleXY.IsEmpty)
{
g.ScaleTransform(p_scaleXY.X, p_scaleXY.Y);
}
}
private void ResetTransGrid()
{
}
protected void DrawGridLine(Graphics g, Rectangle p_rec, Pen p_pen, string[,] arrStrGrid, int p_rowHeight, int[] p_arrColsWidth, GridLineFlag p_gridLineFlag, GridBorderFlag p_gridBorderFlag, PointF p_scaleXY, GridMergeFlag gridMergeFlag)
{
Rectangle rectangle = new Rectangle(p_rec.X, p_rec.Y, p_rec.Width, p_rec.Height);
int length = arrStrGrid.GetLength(0);
int length2 = arrStrGrid.GetLength(1);
if (gridMergeFlag == GridMergeFlag.None)
{
this.DrawGridLine(g, rectangle, p_pen, length, length2, p_rowHeight, p_arrColsWidth, p_gridLineFlag, p_gridBorderFlag, p_scaleXY);
}
else if (p_gridLineFlag != GridLineFlag.None)
{
this.TransGrid(g, rectangle, p_scaleXY);
int[] array = new int[length2];
for (int i = 0; i < length; i++)
{
int num = rectangle.X;
int num2 = rectangle.Y;
for (int j = 0; j < length2; j++)
{
int x = num + p_arrColsWidth[j];
num2 = rectangle.Y + p_rowHeight * i;
int num3 = num2;
if (i > 0)
{
switch (gridMergeFlag)
{
case GridMergeFlag.None:
g.DrawLine(p_pen, num, num2, x, num3);
break;
case GridMergeFlag.Row:
g.DrawLine(p_pen, num, num2, x, num3);
break;
case GridMergeFlag.Col:
if (arrStrGrid[i, j] == "" || arrStrGrid[i, j] != arrStrGrid[i - 1, j])
{
g.DrawLine(p_pen, num, num2, x, num3);
}
break;
case GridMergeFlag.Any:
if (arrStrGrid[i, j] == "" || arrStrGrid[i, j] != arrStrGrid[i - 1, j])
{
g.DrawLine(p_pen, num, num2, x, num3);
}
break;
}
}
if (j > 0)
{
num3 += p_rowHeight;
x = num;
switch (gridMergeFlag)
{
case GridMergeFlag.None:
g.DrawLine(p_pen, num, num2, x, num3);
break;
case GridMergeFlag.Row:
if (arrStrGrid[i, j] == "" || arrStrGrid[i, j] != arrStrGrid[i, j - 1])
{
g.DrawLine(p_pen, num, num2, x, num3);
}
break;
case GridMergeFlag.Col:
g.DrawLine(p_pen, num, num2, x, num3);
break;
case GridMergeFlag.Any:
if (arrStrGrid[i, j] == "" || arrStrGrid[i, j] != arrStrGrid[i, j - 1])
{
g.DrawLine(p_pen, num, num2, x, num3);
}
break;
}
}
num += p_arrColsWidth[j];
}
}
if (p_gridBorderFlag != GridBorderFlag.None)
{
this.DrawGridBorder(g, rectangle, p_pen, p_gridBorderFlag);
}
this.ResetTransGrid();
}
}
protected void DrawGridText(Graphics g, Rectangle p_rec, Brush p_brush, string[,] arrStrGrid, int p_rowHeight, int[] p_arrColsWidth, string alignment, Font p_font, PointF p_scaleXY, GridMergeFlag gridMergeFlag)
{
if (gridMergeFlag == GridMergeFlag.None)
{
this.DrawGridText(g, p_rec, p_brush, arrStrGrid, p_rowHeight, p_arrColsWidth, alignment, p_font, p_scaleXY);
}
else
{
try
{
Rectangle p_rec2 = new Rectangle(p_rec.X, p_rec.Y, p_rec.Width, p_rec.Height);
Font font = p_font;
if (font == null)
{
font = new Font("宋体", 12f);
}
int length = arrStrGrid.GetLength(0);
int length2 = arrStrGrid.GetLength(1);
int[] array = new int[length2];
AlignFlag[] colsAlign = this.GetColsAlign(alignment);
this.TransGrid(g, p_rec2, p_scaleXY);
StringFormat stringFormat = new StringFormat();
stringFormat.LineAlignment = StringAlignment.Center;
stringFormat.FormatFlags = StringFormatFlags.LineLimit;
CellRectangle mergeCell = new CellRectangle(p_rec2.X, p_rec2.Y, 0, p_rowHeight);
for (int i = 0; i < length; i++)
{
for (int j = 0; j < length2; j++)
{
mergeCell = this.GetMergeCell(new Point(p_rec2.X, p_rec2.Y), arrStrGrid, p_rowHeight, p_arrColsWidth, i, j, gridMergeFlag);
Rectangle r = new Rectangle(mergeCell.Left, mergeCell.Top, mergeCell.Width, mergeCell.Height + 4);
stringFormat.Alignment = StringAlignment.Near;
if (colsAlign.Length > j)
{
if (colsAlign[j] == AlignFlag.Center)
{
stringFormat.Alignment = StringAlignment.Center;
}
else if (colsAlign[j] == AlignFlag.Right)
{
stringFormat.Alignment = StringAlignment.Far;
}
}
g.DrawString(arrStrGrid[i, j], font, p_brush, r, stringFormat);
}
}
this.ResetTransGrid();
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
finally
{
}
}
}
protected virtual CellRectangle GetMergeCell(Point GridLocation, string[,] arrStrGrid, int rowHeight, int[] ArrColWidth, int rowSel, int colSel, GridMergeFlag gridMergeFlag)
{
CellRectangle result = new CellRectangle(0, 0, 0, 0);
int length = arrStrGrid.GetLength(0);
int length2 = arrStrGrid.GetLength(1);
int num = 1;
int num2 = 1;
int num3 = rowSel;
int num4 = rowSel;
int num5 = colSel;
int num6 = colSel;
if (gridMergeFlag == GridMergeFlag.Any || gridMergeFlag == GridMergeFlag.Col || gridMergeFlag == GridMergeFlag.ColDependOnBeforeGroup)
{
for (int i = rowSel - 1; i >= 0; i--)
{
if (!(arrStrGrid[rowSel, colSel] == arrStrGrid[i, colSel]))
{
break;
}
num++;
num3--;
}
for (int i = rowSel + 1; i < length; i++)
{
if (!(arrStrGrid[rowSel, colSel] == arrStrGrid[i, colSel]))
{
break;
}
num++;
num4++;
}
}
if (gridMergeFlag == GridMergeFlag.Any || gridMergeFlag == GridMergeFlag.Row)
{
for (int j = colSel - 1; j >= 0; j--)
{
if (!(arrStrGrid[rowSel, colSel] == arrStrGrid[rowSel, j]))
{
break;
}
num2++;
num5--;
}
for (int j = colSel + 1; j < length2; j++)
{
if (!(arrStrGrid[rowSel, colSel] == arrStrGrid[rowSel, j]))
{
break;
}
num2++;
num6++;
}
}
int num7 = GridLocation.X;
int cellTop = GridLocation.Y + num3 * rowHeight;
int num8 = 0;
for (int k = num5 - 1; k >= 0; k--)
{
num7 += ArrColWidth[k];
}
for (int k = num5; k <= num6; k++)
{
num8 += ArrColWidth[k];
}
int cellHeight = num * rowHeight;
result = new CellRectangle(num7, cellTop, num8, cellHeight);
return result;
}
}
}

View File

@ -0,0 +1,171 @@
using System;
using System.Drawing;
namespace GoldPrinter
{
public class DrawRectangle : DrawBase
{
private BordersEdgeFlag _borderEdge;
private Color _backColor;
public BordersEdgeFlag BordersEdge
{
get
{
return this._borderEdge;
}
set
{
this._borderEdge = value;
}
}
public Color BackColor
{
get
{
return this._backColor;
}
set
{
this._backColor = value;
}
}
public DrawRectangle()
{
this._borderEdge = BordersEdgeFlag.FourEdge;
this._backColor = Color.White;
}
public override void Draw()
{
switch (this.BordersEdge)
{
case BordersEdgeFlag.Left:
this.DrawLeftLine();
break;
case BordersEdgeFlag.Right:
this.DrawRightLine();
break;
case BordersEdgeFlag.Top:
this.DrawTopLine();
break;
case BordersEdgeFlag.Bottom:
this.DrawBottomLine();
break;
case BordersEdgeFlag.DiagonalDown:
this.DrawDiagonalDownLine();
break;
case BordersEdgeFlag.DiagonalUp:
this.DrawDiagonalUpLine();
break;
default:
this.Draw(base.Graphics, base.Pen, base.Rectangle);
break;
}
if (this.BackColor != Color.White)
{
this.FillRectangle();
}
}
public void FillRectangle()
{
Pen pen = new Pen(this.BackColor);
base.Brush = pen.Brush;
this.DrawBackColor(base.Graphics, base.Brush, base.Rectangle);
}
public void DrawLeftLine()
{
this.DrawLeftLine(base.Graphics, base.Pen, base.Rectangle);
}
public void DrawRightLine()
{
this.DrawRightLine(base.Graphics, base.Pen, base.Rectangle);
}
public void DrawTopLine()
{
this.DrawTopLine(base.Graphics, base.Pen, base.Rectangle);
}
public void DrawBottomLine()
{
this.DrawBottomLine(base.Graphics, base.Pen, base.Rectangle);
}
public void DrawDiagonalDownLine()
{
this.DrawDiagonalDownLine(base.Graphics, base.Pen, base.Rectangle);
}
public void DrawDiagonalUpLine()
{
this.DrawDiagonalUpLine(base.Graphics, base.Pen, base.Rectangle);
}
protected void Draw(Graphics g, Pen pen, Rectangle rec)
{
g.DrawRectangle(pen, rec.X, rec.Y, rec.Width, rec.Height);
}
protected void DrawLeftLine(Graphics g, Pen pen, Rectangle rec)
{
int left = rec.Left;
int top = rec.Top;
int bottom = rec.Bottom;
g.DrawLine(pen, left, top, left, bottom);
}
protected void DrawRightLine(Graphics g, Pen pen, Rectangle rec)
{
int right = rec.Right;
int top = rec.Top;
int bottom = rec.Bottom;
g.DrawLine(pen, right, top, right, bottom);
}
protected void DrawTopLine(Graphics g, Pen pen, Rectangle rec)
{
int left = rec.Left;
int right = rec.Right;
int top = rec.Top;
g.DrawLine(pen, left, top, right, top);
}
protected void DrawBottomLine(Graphics g, Pen pen, Rectangle rec)
{
int left = rec.Left;
int right = rec.Right;
int bottom = rec.Bottom;
g.DrawLine(pen, left, bottom, right, bottom);
}
protected void DrawDiagonalDownLine(Graphics g, Pen pen, Rectangle rec)
{
int x = rec.X;
int y = rec.Y;
int right = rec.Right;
int bottom = rec.Bottom;
g.DrawLine(pen, x, y, right, bottom);
}
protected void DrawDiagonalUpLine(Graphics g, Pen pen, Rectangle rec)
{
int x = rec.X;
int bottom = rec.Bottom;
int right = rec.Right;
int top = rec.Top;
g.DrawLine(pen, x, bottom, right, top);
}
protected void DrawBackColor(Graphics g, Brush brush, Rectangle rec)
{
g.FillRectangle(brush, rec);
}
}
}

View File

@ -0,0 +1,157 @@
using System;
using System.Drawing;
namespace GoldPrinter
{
public class DrawText : DrawBase
{
private string _text;
private Font _font;
private StringFormat _stringFormat;
private int _startChar;
private int _linesFilled;
private int _charsFitted;
private bool _hasMorePages;
private static int intCurrentCharIndex;
public string Text
{
get
{
return this._text;
}
set
{
this._text = value;
}
}
public Font Font
{
get
{
return this._font;
}
set
{
if (value != null)
{
this._font = value;
}
}
}
public StringFormat StringFormat
{
get
{
return this._stringFormat;
}
set
{
this._stringFormat = value;
}
}
public int StartChar
{
get
{
return this._startChar;
}
set
{
this._startChar = value;
if (this._startChar < 0)
{
this._startChar = 0;
}
else if (this._startChar >= this.Text.Length)
{
this._startChar = this.Text.Length;
}
}
}
public int CharsFitted
{
get
{
return this._charsFitted;
}
}
public int LinesFilled
{
get
{
return this._linesFilled;
}
}
public DrawText()
{
this._text = "";
this._font = new Font("宋体", 10f);
this._startChar = 0;
this._linesFilled = 0;
this._charsFitted = 0;
this._stringFormat = new StringFormat(StringFormatFlags.LineLimit);
}
public DrawText(string text) : this()
{
this._text = text;
}
public override void Dispose()
{
base.Dispose();
this._font.Dispose();
this._stringFormat.Dispose();
}
private void DrawOnePage()
{
if (base.Graphics != null)
{
int charsFitted;
int linesFilled;
base.Graphics.MeasureString(this._text.Substring(this._startChar), this._font, new SizeF((float)base.Rectangle.Width, (float)base.Rectangle.Height), this._stringFormat, out charsFitted, out linesFilled);
base.Graphics.DrawString(this._text.Substring(this._startChar), this._font, base.Brush, base.Rectangle, this._stringFormat);
this._linesFilled = linesFilled;
this._charsFitted = charsFitted;
}
}
public override void Draw()
{
this.DrawOnePage();
}
private bool Draw(DrawText p_drawText, string p_text)
{
DrawText drawText = new DrawText(p_text);
this.StartChar = DrawText.intCurrentCharIndex;
DrawText.intCurrentCharIndex += this.CharsFitted;
bool result;
if (DrawText.intCurrentCharIndex < p_text.Length)
{
result = true;
}
else
{
DrawText.intCurrentCharIndex = 0;
result = false;
}
return result;
}
}
}

View File

@ -0,0 +1,130 @@
using GoldPrinter.ExcelConstants;
using Microsoft.Office.Interop.Excel;
using System;
using System.Data;
using System.Drawing;
namespace GoldPrinter
{
public class ExcelAccess : ExcelBase
{
public void MergeCells(int p_startRowIndex, int p_startColIndex, int p_endRowIndex, int p_endColIndex)
{
base.MergeCells(base.GetRange(p_startRowIndex, p_startColIndex, p_endRowIndex, p_endColIndex));
}
public void MergeCells(int p_startRowIndex, string p_startColChars, int p_endRowIndex, string p_endColChars)
{
base.MergeCells(base.GetRange(p_startRowIndex, p_startColChars, p_endRowIndex, p_endColChars));
}
public void SetFont(int p_startRowIndex, int p_startColIndex, int p_endRowIndex, int p_endColIndex, System.Drawing.Font p_Font)
{
base.SetFont(base.GetRange(p_startRowIndex, p_startColIndex, p_endRowIndex, p_endColIndex), p_Font, Color.Black);
}
public void SetBordersEdge(int p_rowIndex, int p_colIndex, BordersEdge p_BordersEdge, BordersLineStyle p_BordersLineStyle, BordersWeight p_BordersWeight)
{
base.SetBordersEdge(base.GetRange(p_rowIndex, p_colIndex), p_BordersEdge, p_BordersLineStyle, p_BordersWeight);
}
public void SetBordersEdge(int p_rowIndex, string p_colChars, BordersEdge p_BordersEdge, BordersLineStyle p_BordersLineStyle, BordersWeight p_BordersWeight)
{
base.SetBordersEdge(base.GetRange(p_rowIndex, p_colChars), p_BordersEdge, p_BordersLineStyle, p_BordersWeight);
}
public void SetBordersEdge(int p_startRowIndex, int p_startColIndex, int p_endRowIndex, int p_endColIndex, BordersEdge p_BordersEdge, BordersLineStyle p_BordersLineStyle, BordersWeight p_BordersWeight)
{
base.SetBordersEdge(base.GetRange(p_startRowIndex, p_startColIndex, p_endRowIndex, p_endColIndex), p_BordersEdge, p_BordersLineStyle, p_BordersWeight);
}
public void SetBordersEdge(int p_startRowIndex, string p_startColChars, int p_endRowIndex, string p_endColChars, BordersEdge p_BordersEdge, BordersLineStyle p_BordersLineStyle, BordersWeight p_BordersWeight)
{
base.SetBordersEdge(base.GetRange(p_startRowIndex, p_startColChars, p_endRowIndex, p_endColChars), p_BordersEdge, p_BordersLineStyle, p_BordersWeight);
}
public void SetBordersEdge(int p_startRowIndex, int p_startColIndex, int p_endRowIndex, int p_endColIndex, bool IsBordersOrBordersGrid)
{
base.SetBordersEdge(base.GetRange(p_startRowIndex, p_startColIndex, p_endRowIndex, p_endColIndex), BordersEdge.xlLeft);
base.SetBordersEdge(base.GetRange(p_startRowIndex, p_startColIndex, p_endRowIndex, p_endColIndex), BordersEdge.xlTop);
base.SetBordersEdge(base.GetRange(p_startRowIndex, p_startColIndex, p_endRowIndex, p_endColIndex), BordersEdge.xlRight);
base.SetBordersEdge(base.GetRange(p_startRowIndex, p_startColIndex, p_endRowIndex, p_endColIndex), BordersEdge.xlBottom);
if (!IsBordersOrBordersGrid)
{
base.SetBordersEdge(base.GetRange(p_startRowIndex, p_startColIndex, p_endRowIndex, p_endColIndex), BordersEdge.xlInsideHorizontal);
base.SetBordersEdge(base.GetRange(p_startRowIndex, p_startColIndex, p_endRowIndex, p_endColIndex), BordersEdge.xlInsideVertical);
}
}
public void ClearBordersEdge(int p_rowIndex, int p_colIndex)
{
base.SetBordersEdge(base.GetRange(p_rowIndex, p_colIndex), BordersEdge.xlLineStyleNone);
}
public void ClearBordersEdge(int p_rowIndex, string p_colChars)
{
base.SetBordersEdge(base.GetRange(p_rowIndex, p_colChars), BordersEdge.xlLineStyleNone);
}
public void ClearBordersEdge(int p_startRowIndex, int p_startColIndex, int p_endRowIndex, int p_endColIndex)
{
base.SetBordersEdge(base.GetRange(p_startRowIndex, p_startColIndex, p_endRowIndex, p_endColIndex), BordersEdge.xlLineStyleNone);
}
public void ClearBordersEdge(int p_startRowIndex, string p_startColChars, int p_endRowIndex, string p_endColChars)
{
base.SetBordersEdge(base.GetRange(p_startRowIndex, p_startColChars, p_endRowIndex, p_endColChars), BordersEdge.xlLineStyleNone);
}
public string GetCellText(int p_rowIndex, int p_colIndex)
{
Range range = base.GetRange(p_rowIndex, p_colIndex);
return range.Text.ToString();
}
public string GetCellText(int p_rowIndex, string p_colChars)
{
Range range = base.GetRange(p_rowIndex, p_colChars);
return range.Text.ToString();
}
public void SetCellText(int p_rowIndex, int p_colIndex, string p_text)
{
Range range = base.GetRange(p_rowIndex, p_colIndex);
range.Cells.FormulaR1C1 = p_text;
}
public void SetCellText(int p_rowIndex, string p_colChars, string p_text)
{
Range range = base.GetRange(p_rowIndex, p_colChars);
range.Cells.FormulaR1C1 = p_text;
}
public void SetCellText(int p_startRowIndex, int p_startColIndex, int p_endRowIndex, int p_endColIndex, string p_text)
{
Range range = base.GetRange(p_startRowIndex, p_startColIndex, p_endRowIndex, p_endColIndex);
range.Cells.FormulaR1C1 = p_text;
}
public void SetCellText(int p_startRowIndex, string p_startColChars, int p_endRowIndex, string p_endColChars, string p_text)
{
Range range = base.GetRange(p_startRowIndex, p_startColChars, p_endRowIndex, p_endColChars);
range.Cells.FormulaR1C1 = p_text;
}
public void SetCellText(System.Data.DataTable p_DataTable, int p_startExcelRowIndex, int p_startExcelColIndex, bool IsDrawGridLine)
{
for (int i = 0; i < p_DataTable.Rows.Count; i++)
{
for (int j = 0; j < p_DataTable.Columns.Count; j++)
{
this.SetCellText(p_startExcelRowIndex + i, p_startExcelColIndex + j, p_DataTable.Rows[i][j].ToString());
}
}
if (IsDrawGridLine)
{
this.SetBordersEdge(p_startExcelRowIndex, p_startExcelColIndex, p_startExcelRowIndex + p_DataTable.Rows.Count - 1, p_startExcelColIndex + p_DataTable.Columns.Count - 1, false);
}
}
}
}

View File

@ -0,0 +1,424 @@
using GoldPrinter.ExcelConstants;
using Microsoft.Office.Interop.Excel;
using System;
using System.Drawing;
using System.IO;
using System.Reflection;
namespace GoldPrinter
{
public class ExcelBase
{
private Application _xlApp;
private Workbook _xlWorkbook;
private bool _IsVisibledExcel;
private string _FormCaption;
private object oMissing = Missing.Value;
public Application Application
{
get
{
return this._xlApp;
}
}
public Workbook Workbooks
{
get
{
return this._xlWorkbook;
}
}
public bool IsVisibledExcel
{
get
{
return this._IsVisibledExcel;
}
set
{
this._IsVisibledExcel = value;
}
}
public string FormCaption
{
get
{
return this._FormCaption;
}
set
{
this._FormCaption = value;
}
}
public ExcelBase()
{
this._IsVisibledExcel = false;
this._FormCaption = "打印预览";
try
{
this._xlApp = new ApplicationClass();
}
catch (Exception ex)
{
throw new ExceptionExcelCreateInstance("创建Excel类实例时错误详细信息" + ex.Message);
}
this._xlApp.DisplayAlerts = false;
}
public void Open()
{
try
{
this._xlWorkbook = this._xlApp.Workbooks.Add(this.oMissing);
}
catch (Exception ex)
{
throw new ExceptionExcelOpen("打开Excel时错误详细信息" + ex.Message);
}
}
public void Open(string p_templateFileName)
{
if (File.Exists(p_templateFileName))
{
try
{
this._xlWorkbook = this._xlApp.Workbooks.Add(p_templateFileName);
}
catch (Exception ex)
{
throw new ExceptionExcelOpen("打开Excel时错误详细信息" + ex.Message);
}
}
else
{
this.Open();
}
}
public void Close()
{
this._xlApp.Workbooks.Close();
this._xlWorkbook = null;
this._xlApp.Quit();
this._xlApp = null;
this.oMissing = null;
GC.Collect();
}
public void ShowExcel()
{
this._xlApp.Visible = true;
}
public void PrintPreview()
{
this._xlApp.Caption = this._FormCaption;
this._xlApp.Visible = true;
try
{
this._xlApp.ActiveWorkbook.PrintPreview(this.oMissing);
}
catch
{
}
this._xlApp.Visible = this.IsVisibledExcel;
}
public void Print()
{
this._xlApp.Visible = this.IsVisibledExcel;
object value = Missing.Value;
try
{
this._xlApp.ActiveWorkbook.PrintOut(value, value, value, value, value, value, value, value);
}
catch
{
}
}
public bool SaveAs(string p_fileName, bool p_ReplaceExistsFileName)
{
bool result = false;
if (File.Exists(p_fileName))
{
if (p_ReplaceExistsFileName)
{
try
{
File.Delete(p_fileName);
result = true;
}
catch (Exception ex)
{
string message = ex.Message;
}
}
}
try
{
this._xlApp.ActiveWorkbook.SaveCopyAs(p_fileName);
result = true;
}
catch
{
result = false;
}
return result;
}
public Range GetRange(int p_rowIndex, int p_colIndex)
{
return this.GetRange(p_rowIndex, p_colIndex, p_rowIndex, p_colIndex);
}
public Range GetRange(int p_rowIndex, string p_colChars)
{
return this.GetRange(p_rowIndex, p_colChars, p_rowIndex, p_colChars);
}
public Range GetRange(int p_startRowIndex, int p_startColIndex, int p_endRowIndex, int p_endColIndex)
{
return this._xlApp.get_Range(this._xlApp.Cells[p_startRowIndex, p_startColIndex], this._xlApp.Cells[p_endRowIndex, p_endColIndex]);
}
public Range GetRange(int p_startRowIndex, string p_startColChars, int p_endRowIndex, string p_endColChars)
{
return this._xlApp.get_Range(p_startColChars + p_startRowIndex.ToString(), p_endColChars + p_endRowIndex.ToString());
}
public void MergeCells(Range p_Range)
{
p_Range.HorizontalAlignment = Constants.xlCenter;
p_Range.VerticalAlignment = Constants.xlCenter;
p_Range.WrapText = false;
p_Range.Orientation = 0;
p_Range.AddIndent = false;
p_Range.IndentLevel = 0;
p_Range.ShrinkToFit = false;
p_Range.MergeCells = false;
p_Range.Merge(this.oMissing);
}
public void InsertVPageBreaks(int p_rowIndex)
{
}
public void InsertHPageBreaks(int p_colIndex)
{
}
public void InsertHPageBreaks(string p_colChars)
{
}
public void InsertRow(int p_rowIndex)
{
Range range = this.GetRange(p_rowIndex, "A");
range.Select();
range.EntireRow.Insert(this.oMissing, Missing.Value);
}
public void InsertRow(int p_rowIndex, int p_templateRowIndex)
{
Range range = (Range)this._xlApp.Rows[p_templateRowIndex.ToString() + ":" + p_templateRowIndex.ToString(), this.oMissing];
range.Select();
range.Copy(this.oMissing);
this.InsertRow(p_rowIndex);
}
public void InsertColumn(int p_colIndex)
{
Range range = this.GetRange(1, p_colIndex);
range.Select();
range.EntireColumn.Insert(this.oMissing, Missing.Value);
}
public void InsertColumn(string p_colChars)
{
Range range = this.GetRange(1, p_colChars);
range.Select();
range.EntireColumn.Insert(this.oMissing, Missing.Value);
}
public void DeleteRow(int p_rowIndex)
{
Range range = this.GetRange(p_rowIndex, "A");
range.Select();
range.EntireRow.Delete(this.oMissing);
}
public void DeleteColumn(int p_colIndex)
{
Range range = this.GetRange(1, p_colIndex);
range.Select();
range.EntireColumn.Delete(this.oMissing);
}
public void DeleteColumn(string p_colChars)
{
Range range = this.GetRange(1, p_colChars);
range.Select();
range.EntireColumn.Delete(this.oMissing);
}
public void SetRowHeight(int p_rowIndex, float p_rowHeight)
{
Range range = this.GetRange(p_rowIndex, "A");
range.Select();
range.RowHeight = p_rowHeight;
}
public void SetColumnWidth(int p_colIndex, float p_colWidth)
{
Range range = this.GetRange(1, p_colIndex);
range.Select();
range.ColumnWidth = p_colWidth;
}
public void SetColumnWidth(string p_colChars, float p_colWidth)
{
Range range = this.GetRange(1, p_colChars);
range.Select();
range.ColumnWidth = p_colWidth;
}
public void SetFont(Range p_Range, System.Drawing.Font p_Font)
{
this.SetFont(p_Range, p_Font, Color.Black);
}
public void SetFont(Range p_Range, System.Drawing.Font p_Font, Color p_color)
{
p_Range.Select();
p_Range.Font.Name = p_Font.Name;
p_Range.Font.Size = p_Font.Size;
p_Range.Font.Bold = p_Font.Bold;
p_Range.Font.Italic = p_Font.Italic;
p_Range.Font.Strikethrough = p_Font.Strikeout;
p_Range.Font.Underline = p_Font.Underline;
}
public void SetBordersEdge(Range p_Range, BordersEdge p_BordersEdge)
{
this.SetBordersEdge(p_Range, p_BordersEdge, BordersLineStyle.xlContinuous, BordersWeight.xlThin);
}
public void SetBordersEdge(Range p_Range, BordersEdge p_BordersEdge, BordersLineStyle p_BordersLineStyle, BordersWeight p_BordersWeight)
{
p_Range.Select();
Border border = null;
switch (p_BordersEdge)
{
case BordersEdge.xlLineStyleNone:
p_Range.Borders[XlBordersIndex.xlDiagonalDown].LineStyle = XlLineStyle.xlLineStyleNone;
p_Range.Borders[XlBordersIndex.xlDiagonalUp].LineStyle = XlLineStyle.xlLineStyleNone;
p_Range.Borders[XlBordersIndex.xlEdgeLeft].LineStyle = XlLineStyle.xlLineStyleNone;
p_Range.Borders[XlBordersIndex.xlEdgeTop].LineStyle = XlLineStyle.xlLineStyleNone;
p_Range.Borders[XlBordersIndex.xlEdgeBottom].LineStyle = XlLineStyle.xlLineStyleNone;
p_Range.Borders[XlBordersIndex.xlEdgeRight].LineStyle = XlLineStyle.xlLineStyleNone;
p_Range.Borders[XlBordersIndex.xlInsideVertical].LineStyle = XlLineStyle.xlLineStyleNone;
p_Range.Borders[XlBordersIndex.xlInsideHorizontal].LineStyle = XlLineStyle.xlLineStyleNone;
break;
case BordersEdge.xlLeft:
border = p_Range.Borders[XlBordersIndex.xlEdgeLeft];
break;
case BordersEdge.xlRight:
border = p_Range.Borders[XlBordersIndex.xlEdgeRight];
break;
case BordersEdge.xlTop:
border = p_Range.Borders[XlBordersIndex.xlEdgeTop];
break;
case BordersEdge.xlBottom:
border = p_Range.Borders[XlBordersIndex.xlEdgeBottom];
break;
case BordersEdge.xlDiagonalDown:
border = p_Range.Borders[XlBordersIndex.xlDiagonalDown];
break;
case BordersEdge.xlDiagonalUp:
border = p_Range.Borders[XlBordersIndex.xlDiagonalUp];
break;
case BordersEdge.xlInsideHorizontal:
border = p_Range.Borders[XlBordersIndex.xlInsideHorizontal];
break;
case BordersEdge.xlInsideVertical:
border = p_Range.Borders[XlBordersIndex.xlInsideVertical];
break;
}
if (border != null)
{
XlLineStyle xlLineStyle = XlLineStyle.xlContinuous;
switch (p_BordersLineStyle)
{
case BordersLineStyle.xlContinuous:
xlLineStyle = XlLineStyle.xlContinuous;
break;
case BordersLineStyle.xlDash:
xlLineStyle = XlLineStyle.xlDash;
break;
case BordersLineStyle.xlDashDot:
xlLineStyle = XlLineStyle.xlDashDot;
break;
case BordersLineStyle.xlDashDotDot:
xlLineStyle = XlLineStyle.xlDashDotDot;
break;
case BordersLineStyle.xlDot:
xlLineStyle = XlLineStyle.xlDot;
break;
case BordersLineStyle.xlDouble:
xlLineStyle = XlLineStyle.xlDouble;
break;
case BordersLineStyle.xlLineStyleNone:
xlLineStyle = XlLineStyle.xlLineStyleNone;
break;
case BordersLineStyle.xlSlantDashDot:
xlLineStyle = XlLineStyle.xlSlantDashDot;
break;
}
border.LineStyle = xlLineStyle;
XlBorderWeight xlBorderWeight = XlBorderWeight.xlThin;
switch (p_BordersWeight)
{
case BordersWeight.xlHairline:
xlBorderWeight = XlBorderWeight.xlHairline;
break;
case BordersWeight.xlMedium:
xlBorderWeight = XlBorderWeight.xlMedium;
break;
case BordersWeight.xlThick:
xlBorderWeight = XlBorderWeight.xlThick;
break;
case BordersWeight.xlThin:
xlBorderWeight = XlBorderWeight.xlThin;
break;
}
border.Weight = xlBorderWeight;
}
}
public void ClearBordersEdge(Range p_Range)
{
this.SetBordersEdge(p_Range, BordersEdge.xlLineStyleNone);
}
public string GetCellText(Range p_Range)
{
return p_Range.Text.ToString();
}
public void SetCellText(Range p_Range, string p_text)
{
p_Range.Cells.FormulaR1C1 = p_text;
}
}
}

View File

@ -0,0 +1,26 @@
using System;
namespace GoldPrinter
{
public class ExceptionExcelCreateInstance : Exception
{
private string _Message = "创建Excel类实例时错误";
public override string Message
{
get
{
return this._Message;
}
}
public ExceptionExcelCreateInstance()
{
}
public ExceptionExcelCreateInstance(string message)
{
this._Message = message;
}
}
}

View File

@ -0,0 +1,26 @@
using System;
namespace GoldPrinter
{
public class ExceptionExcelOpen : Exception
{
private string _Message = "打开Excel时错误";
public override string Message
{
get
{
return this._Message;
}
}
public ExceptionExcelOpen()
{
}
public ExceptionExcelOpen(string message)
{
this._Message = message;
}
}
}

View File

@ -0,0 +1,26 @@
using System;
namespace GoldPrinter
{
public class ExceptionInvalidPrinter : Exception
{
private string _Message = "无效的打印机,请在控制面版中添加打印机!";
public override string Message
{
get
{
return this._Message;
}
}
public ExceptionInvalidPrinter()
{
}
public ExceptionInvalidPrinter(string message)
{
this._Message = message;
}
}
}

View File

@ -0,0 +1,16 @@
using System;
namespace GoldPrinter
{
public class Footer : Outer
{
public Footer()
{
}
public Footer(int rows, int cols) : this()
{
base.Initialize(rows, cols);
}
}
}

View File

@ -0,0 +1,319 @@
using System;
using System.Data;
using System.Drawing;
using System.Windows.Forms;
namespace GoldPrinter
{
public class GoldGrid : GridBase
{
private string _colsAlignList = "";
private object _DataSource = null;
public string ColsAlignString
{
get
{
return this._colsAlignList;
}
set
{
if (value != null)
{
this._colsAlignList = value;
}
}
}
public object DataSource
{
get
{
return this._DataSource;
}
set
{
if (value != null)
{
this._DataSource = value;
string text = value.GetType().ToString();
switch (text)
{
case "System.String[]":
{
string[] array = (string[])this._DataSource;
string[,] array2 = new string[1, array.Length];
for (int i = 0; i < array.Length; i++)
{
array2[0, i] = array[i];
}
this.DataSource = array2;
break;
}
case "System.String[,]":
base.GridText = (string[,])this._DataSource;
break;
case "System.Data.DataTable":
base.GridText = this.ToArrFromDataTable((DataTable)this._DataSource);
break;
case "System.Windows.Forms.DataGrid":
base.GridText = this.ToArrFromDataGrid((System.Windows.Forms.DataGrid)this._DataSource);
break;
}
}
}
}
public void SetText(int row, int col, string text)
{
this._arrStrGrid[row, col] = text;
}
public void SetText(string text)
{
this._arrStrGrid[base.RowSel, base.ColSel] = text;
}
public string GetText(int row, int col)
{
return this._arrStrGrid[row, col];
}
public string GetText()
{
return this._arrStrGrid[base.RowSel, base.ColSel];
}
public void SetTextOnRowSel(int rowSel, int startCol, int endCol, string text)
{
for (int i = startCol; i <= endCol; i++)
{
this.SetText(rowSel, i, text);
}
}
public void SetTextOnColSel(int colSel, int startRow, int endRow, string text)
{
for (int i = startRow; i <= endRow; i++)
{
this.SetText(i, colSel, text);
}
}
public CellRectangle GetMergeCell()
{
return this.GetMergeCell(base.Location, this._arrStrGrid, base.PreferredRowHeight, base.ColsWidth, base.RowSel, base.ColSel);
}
private void InitColsAlignString()
{
string text = "";
string str = "";
switch (base.AlignMent)
{
case AlignFlag.Left:
str = "L";
break;
case AlignFlag.Center:
str = "C";
break;
case AlignFlag.Right:
str = "R";
break;
}
for (int i = this._colsAlignList.Length; i < base.Cols; i++)
{
text += str;
}
this._colsAlignList = text;
if (this._colsAlignList.Length > base.Cols)
{
this._colsAlignList.Substring(0, base.Cols);
}
}
public string[,] ToArrFromDataTable(DataTable source)
{
string[,] result;
if (source == null)
{
result = new string[0, 0];
}
else
{
int count = source.Rows.Count;
int count2 = source.Columns.Count;
string[,] array = new string[count, count2];
for (int i = 0; i < count; i++)
{
for (int j = 0; j < count2; j++)
{
array[i, j] = source.Rows[i][j].ToString();
}
}
result = array;
}
return result;
}
public string[,] ToArrFromDataGrid(System.Windows.Forms.DataGrid source)
{
string[,] result;
if (source == null)
{
result = new string[0, 0];
}
else
{
int num = 0;
int num2 = 0;
try
{
for (int i = 0; i < 2147483646; i++)
{
string text = source[0, i].ToString();
num2++;
}
}
catch (Exception var_5_5A)
{
}
try
{
for (int i = 0; i < 2147483646; i++)
{
string text = source[i, 0].ToString();
num++;
}
}
catch (Exception var_5_5A)
{
}
string[,] array = new string[num, num2];
try
{
for (int i = 0; i < num; i++)
{
for (int j = 0; j < num2; j++)
{
array[i, j] = source[i, j].ToString();
}
}
}
catch (Exception var_5_5A)
{
}
result = array;
}
return result;
}
protected virtual AlignFlag[] GetColsAlign(string alignment)
{
AlignFlag[] result;
if (alignment == null || alignment.Length == 0)
{
result = new AlignFlag[0];
}
else
{
int length = alignment.Length;
AlignFlag[] array = new AlignFlag[length];
int i = 0;
while (i < length)
{
string text = alignment.Substring(i, 1).ToUpper();
string text2 = text;
if (text2 == null)
{
goto IL_7C;
}
if (!(text2 == "C"))
{
if (!(text2 == "R"))
{
goto IL_7C;
}
array[i] = AlignFlag.Right;
}
else
{
array[i] = AlignFlag.Center;
}
IL_82:
i++;
continue;
IL_7C:
array[i] = AlignFlag.Left;
goto IL_82;
}
result = array;
}
return result;
}
protected virtual CellRectangle GetMergeCell(Point GridLocation, string[,] arrStrGrid, int rowHeight, int[] ArrColWidth, int rowSel, int colSel)
{
CellRectangle result = new CellRectangle(0, 0, 0, 0);
int length = arrStrGrid.GetLength(0);
int length2 = arrStrGrid.GetLength(1);
int num = 1;
int num2 = 1;
int num3 = rowSel;
int num4 = rowSel;
int num5 = colSel;
int num6 = colSel;
for (int i = rowSel - 1; i >= 0; i--)
{
if (!(arrStrGrid[rowSel, colSel] == arrStrGrid[i, colSel]))
{
break;
}
num++;
num3--;
}
for (int i = rowSel + 1; i < length; i++)
{
if (!(arrStrGrid[rowSel, colSel] == arrStrGrid[i, colSel]))
{
break;
}
num++;
num4++;
}
for (int j = colSel - 1; j >= 0; j--)
{
if (!(arrStrGrid[rowSel, colSel] == arrStrGrid[rowSel, j]))
{
break;
}
num2++;
num5--;
}
for (int j = colSel + 1; j < length2; j++)
{
if (!(arrStrGrid[rowSel, colSel] == arrStrGrid[rowSel, j]))
{
break;
}
num2++;
num6++;
}
int num7 = GridLocation.X;
int cellTop = GridLocation.Y + num3 * rowHeight;
int num8 = 0;
for (int k = num5 - 1; k >= 0; k--)
{
num7 += ArrColWidth[k];
}
for (int k = num5; k <= num6; k++)
{
num8 += ArrColWidth[k];
}
int cellHeight = num * rowHeight;
result = new CellRectangle(num7, cellTop, num8, cellHeight);
return result;
}
}
}

View File

@ -0,0 +1,698 @@
using System;
using System.Collections;
using System.Drawing;
namespace GoldPrinter
{
public class GridBase : IGrid, IDisposable
{
protected ArrayList _arrRowsHeight;
protected ArrayList _arrColsWidth;
protected ArrayList _arrColsAlign;
protected string[,] _arrStrGrid = new string[0, 0];
private Point _location = new Point(0, 0);
private int _Width = 300;
private int _Height = 200;
private Font _font = new Font("宋体", 10f);
private AlignFlag _alignFlag = AlignFlag.Left;
private GridLineFlag _gridLineFlag = GridLineFlag.Both;
private GridMergeFlag _gridMergeFlag = GridMergeFlag.None;
private GridBorderFlag _gridBorderFlag = GridBorderFlag.Single;
private int _rows = 0;
private int _cols = 0;
private int _fixedRows = 0;
private int _fixedCols = 0;
private int _row = 0;
private int _col = 0;
private int _rowSel = 0;
private int _colSel = 0;
private int _rowheight = 20;
private int _colWidth = 75;
public Point Location
{
get
{
return this._location;
}
set
{
this._location = value;
}
}
public int Width
{
get
{
return this._Width;
}
set
{
this._Width = this.GetValidIntValue(value);
}
}
public int Height
{
get
{
return this._Height;
}
set
{
this._Height = this.GetValidIntValue(value);
}
}
public Font Font
{
get
{
return this._font;
}
set
{
this._font = value;
}
}
public AlignFlag AlignMent
{
get
{
return this._alignFlag;
}
set
{
this._alignFlag = value;
this.ChangeFieldAlignMent();
}
}
public GridLineFlag Line
{
get
{
return this._gridLineFlag;
}
set
{
this._gridLineFlag = value;
}
}
public GridMergeFlag Merge
{
get
{
return this._gridMergeFlag;
}
set
{
this._gridMergeFlag = value;
}
}
public GridBorderFlag Border
{
get
{
return this._gridBorderFlag;
}
set
{
this._gridBorderFlag = value;
}
}
public int Rows
{
get
{
return this._rows;
}
set
{
this._rows = this.GetValidIntValue(value);
this.ChangeFieldRows();
}
}
public int Cols
{
get
{
return this._cols;
}
set
{
this._cols = this.GetValidIntValue(value);
this.ChangeFieldCols();
}
}
public int FixedRows
{
get
{
return this._fixedRows;
}
set
{
this._fixedRows = this.GetValidIntValue(value);
if (this._fixedRows > this.Rows)
{
this._fixedRows = this.Rows;
}
}
}
public int FixedCols
{
get
{
return this._fixedCols;
}
set
{
this._fixedCols = this.GetValidIntValue(value);
if (this._fixedCols > this.Cols)
{
this._fixedCols = this.Cols;
}
}
}
public int Row
{
get
{
return this._row;
}
set
{
this._row = this.GetValidIntValue(value);
if (this._row >= this.Rows)
{
this._row = this.Rows - 1;
}
}
}
public int Col
{
get
{
return this._col;
}
set
{
this._col = this.GetValidIntValue(value);
if (this._col >= this.Cols)
{
this._col = this.Cols - 1;
}
}
}
public int RowSel
{
get
{
return this._rowSel;
}
set
{
int num = this.GetValidIntValue(value);
if (num >= this._rows)
{
num = this._rows - 1;
}
this._rowSel = num;
}
}
public int ColSel
{
get
{
return this._colSel;
}
set
{
int num = this.GetValidIntValue(value);
if (num >= this._cols)
{
num = this._cols - 1;
}
this._rowSel = num;
}
}
public int PreferredRowHeight
{
get
{
return this._rowheight;
}
set
{
this._rowheight = this.GetValidIntValue(value);
this.ChangeFieldPreferredRowHeight();
}
}
public int PreferredColWidth
{
get
{
return this._rowheight;
}
set
{
this._rowheight = this.GetValidIntValue(value);
this.ChangeFieldPreferredColWidth();
}
}
public int[] RowsHeight
{
get
{
int[] array = new int[this._rows];
for (int i = 0; i < this._rows; i++)
{
array[i] = (int)this._arrRowsHeight[i];
}
return array;
}
set
{
int num = 0;
while (num < this._rows && num < value.Length)
{
this._arrRowsHeight[num] = value[num];
num++;
}
}
}
public int[] ColsWidth
{
get
{
int[] array = new int[this._cols];
for (int i = 0; i < this._cols; i++)
{
array[i] = (int)this._arrColsWidth[i];
}
return array;
}
set
{
int num = 0;
while (num < this._cols && num < value.Length)
{
this._arrColsWidth[num] = value[num];
num++;
}
}
}
public AlignFlag[] ColsAlignment
{
get
{
AlignFlag[] array = new AlignFlag[this._cols];
for (int i = 0; i < this._cols; i++)
{
array[i] = (AlignFlag)this._arrColsAlign[i];
}
return array;
}
set
{
AlignFlag[] array = new AlignFlag[this._cols];
int num = 0;
while (num < this._cols && num < array.Length)
{
this._arrColsAlign[num] = array[num];
num++;
}
}
}
public string Text
{
get
{
return this._arrStrGrid[this._row, this._col];
}
set
{
this._arrStrGrid[this._row, this._col] = value;
}
}
public string[,] GridText
{
get
{
return this._arrStrGrid;
}
set
{
this._arrStrGrid = value;
this._rows = this._arrStrGrid.GetLength(0);
this._cols = this._arrStrGrid.GetLength(1);
this.InitRowHeight();
this.InitColWidth();
this.InitColAlignMent();
}
}
private int GetValidIntValue(int val)
{
int num = val;
if (num < 0)
{
num = 0;
}
if (num > 2147483647)
{
num = 2147483647;
}
return num;
}
public int get_RowHeight(int index)
{
return (int)this._arrRowsHeight[index];
}
public void set_RowHeight(int index, int rowHeight)
{
int validIntValue = this.GetValidIntValue(rowHeight);
this._arrRowsHeight[index] = validIntValue;
}
public int get_ColWidth(int index)
{
return (int)this._arrColsWidth[index];
}
public void set_ColWidth(int index, int colWidth)
{
int validIntValue = this.GetValidIntValue(colWidth);
this._arrColsWidth[index] = validIntValue;
}
public AlignFlag get_ColAlignment(int index)
{
return (AlignFlag)this._arrColsAlign[index];
}
public void set_ColAlignment(int index, AlignFlag colAlignment)
{
this._arrColsAlign[index] = colAlignment;
}
public string get_TextMatrix(int row, int col)
{
return this._arrStrGrid[row, col];
}
public void set_TextMatrix(int row, int col, string textMatrix)
{
this._arrStrGrid[row, col] = textMatrix;
}
protected virtual void ChangeFieldPreferredRowHeight()
{
this.InitRowHeight();
}
protected virtual void ChangeFieldPreferredColWidth()
{
this.InitColWidth();
}
protected virtual void ChangeFieldAlignMent()
{
this.InitColAlignMent();
}
protected virtual void ChangeFieldRows()
{
this.ReDimArrString(ref this._arrStrGrid, this._rows, this._cols);
this.ResetRowHeight();
}
protected virtual void ChangeFieldCols()
{
this.ReDimArrString(ref this._arrStrGrid, this._rows, this._cols);
this.ResetColWidth();
}
protected void InitRowHeight()
{
this._arrRowsHeight = new ArrayList();
for (int i = 0; i < this._rows; i++)
{
this._arrRowsHeight.Add(this._rowheight);
}
}
protected void InitColWidth()
{
this._arrColsWidth = new ArrayList();
for (int i = 0; i < this._cols; i++)
{
this._arrColsWidth.Add(this._colWidth);
}
}
protected void InitColAlignMent()
{
this._arrColsAlign = new ArrayList();
for (int i = 0; i < this._cols; i++)
{
this._arrColsAlign.Add(this._alignFlag);
}
}
protected void ResetRowHeight()
{
int num = this._arrRowsHeight.Count - this._cols;
if (num > 0)
{
num = Math.Abs(num);
for (int i = 0; i < num; i++)
{
this._arrRowsHeight.RemoveAt(this._arrRowsHeight.Count - 1);
}
}
else if (num < 0)
{
num = Math.Abs(num);
for (int i = 0; i < num; i++)
{
this._arrRowsHeight.Add(this._rowheight);
}
}
}
protected void ResetColWidth()
{
int num = this._arrColsWidth.Count - this._cols;
if (num > 0)
{
num = Math.Abs(num);
for (int i = 0; i < num; i++)
{
this._arrColsWidth.RemoveAt(this._arrColsWidth.Count - 1);
}
}
else if (num < 0)
{
num = Math.Abs(num);
for (int i = 0; i < num; i++)
{
this._arrColsWidth.Add(this._colWidth);
}
}
}
public virtual void Dispose()
{
this.Font.Dispose();
}
public GridBase() : this(3, 4)
{
}
public GridBase(int rows, int cols)
{
this._rows = rows;
this._cols = cols;
this.Initialize(rows, cols);
}
public IGrid Clone()
{
return (IGrid)base.MemberwiseClone();
}
public void Initialize(int rows, int cols)
{
this._rows = rows;
this._cols = cols;
this.ReDimArrString(ref this._arrStrGrid, rows, cols);
this.InitRowHeight();
this.InitColWidth();
this.InitColAlignMent();
}
public int GetAllColsWidthSum()
{
int num = 0;
for (int i = 0; i < this.Cols; i++)
{
num += (int)this._arrColsWidth[i];
}
return num;
}
public int GetAllRowsHeightSum()
{
int num = 0;
for (int i = 0; i < this.Rows; i++)
{
num += (int)this._arrRowsHeight[i];
}
return num;
}
public int[] GetAverageColsWidth()
{
int[] array = new int[this._cols];
int num = 0;
int num2 = this._Width / this._cols;
for (int i = 0; i < this._cols - 1; i++)
{
array[i] = num2;
num++;
}
array[array.Length - 1] = this._Width - num2 * num;
return array;
}
protected void ReDimArrString(ref string[,] arrStr, int rows, int cols)
{
if (arrStr == null || arrStr.Length == 0)
{
arrStr = new string[rows, cols];
for (int i = 0; i < rows; i++)
{
for (int j = 0; j < cols; j++)
{
arrStr[i, j] = "";
}
}
}
else
{
string[,] array = new string[rows, cols];
int length = arrStr.GetLength(0);
int length2 = arrStr.GetLength(1);
int num = 0;
int num2 = 0;
if (rows >= length)
{
if (cols >= length2)
{
num = length;
num2 = length2;
for (int i = 0; i < length; i++)
{
for (int j = 0; j < cols; j++)
{
array[i, j] = "";
}
}
for (int i = length; i < rows; i++)
{
for (int j = 0; j < cols; j++)
{
array[i, j] = "";
}
}
}
if (cols <= length2)
{
num = length;
num2 = cols;
for (int i = length; i < rows; i++)
{
for (int j = 0; j < length2; j++)
{
array[i, j] = "";
}
}
}
}
if (rows <= length)
{
if (cols >= length2)
{
num = rows;
num2 = length2;
for (int i = 0; i < length; i++)
{
for (int j = length2; j < cols; j++)
{
array[i, j] = "";
}
}
}
if (cols <= length2)
{
num = rows;
num2 = cols;
}
}
for (int i = 0; i < num; i++)
{
for (int j = 0; j < num2; j++)
{
array[i, j] = arrStr[i, j];
}
}
arrStr = array;
}
}
}
}

View File

@ -0,0 +1,13 @@
using System;
namespace GoldPrinter
{
public enum GridBorderFlag
{
None,
Single,
SingleBold,
Double,
DoubleBold
}
}

View File

@ -0,0 +1,12 @@
using System;
namespace GoldPrinter
{
public enum GridLineFlag
{
None,
Horizontal,
Vertical,
Both
}
}

View File

@ -0,0 +1,14 @@
using System;
namespace GoldPrinter
{
public enum GridMergeFlag
{
None,
Row,
Col,
ColDependOnBeforeGroup,
Both,
Any
}
}

View File

@ -0,0 +1,11 @@
using System;
namespace GoldPrinter
{
public enum HAlignFlag
{
Left,
Center,
Right
}
}

View File

@ -0,0 +1,40 @@
using System;
namespace GoldPrinter
{
public class Header : Outer
{
private const int CONST_MAX_ROWS = 10;
private readonly int MAX_ROWS;
public Header()
{
this.MAX_ROWS = this.SetMaxRows();
}
protected virtual int SetMaxRows()
{
return 10;
}
public Header(int rows, int cols) : this()
{
this.Initialize(rows, cols);
}
public override void Initialize(int rows, int cols)
{
int num = rows;
if (num < 0)
{
num = 0;
}
if (num > this.MAX_ROWS)
{
throw new Exception("行数限制在“" + this.MAX_ROWS.ToString() + "”行以内!");
}
base.Initialize(num, cols);
}
}
}

View File

@ -0,0 +1,22 @@
using System;
using System.Drawing;
namespace GoldPrinter
{
public interface IDraw
{
Graphics Graphics
{
get;
set;
}
Rectangle Rectangle
{
get;
set;
}
void Draw();
}
}

View File

@ -0,0 +1,162 @@
using System;
using System.Drawing;
namespace GoldPrinter
{
public interface IGrid
{
Point Location
{
get;
set;
}
int Width
{
get;
set;
}
int Height
{
get;
set;
}
Font Font
{
get;
set;
}
AlignFlag AlignMent
{
get;
set;
}
GridLineFlag Line
{
get;
set;
}
GridMergeFlag Merge
{
get;
set;
}
GridBorderFlag Border
{
get;
set;
}
int Rows
{
get;
set;
}
int Cols
{
get;
set;
}
int FixedRows
{
get;
set;
}
int FixedCols
{
get;
set;
}
int PreferredRowHeight
{
get;
set;
}
int PreferredColWidth
{
get;
set;
}
int[] RowsHeight
{
get;
set;
}
int[] ColsWidth
{
get;
set;
}
AlignFlag[] ColsAlignment
{
get;
set;
}
string Text
{
get;
set;
}
string[,] GridText
{
get;
set;
}
int Row
{
get;
set;
}
int Col
{
get;
set;
}
int RowSel
{
get;
set;
}
int ColSel
{
get;
set;
}
string get_TextMatrix(int row, int col);
void set_TextMatrix(int row, int col, string textMatrix);
int get_RowHeight(int index);
void set_RowHeight(int index, int rowHeight);
int get_ColWidth(int index);
void set_ColWidth(int index, int colWidth);
AlignFlag get_ColAlignment(int index);
void set_ColAlignment(int index, AlignFlag colAlignment);
}
}

View File

@ -0,0 +1,34 @@
using System;
using System.Drawing.Printing;
namespace GoldPrinter
{
public interface IPrinterPageSetting
{
event PrintPageDelegate PrintPage;
PrintDocument PrintDocument
{
get;
set;
}
PrintPageDelegate PrintPageValue
{
get;
set;
}
ImportExcelDelegate ImportExcelValue
{
get;
set;
}
PageSettings ShowPageSetupDialog();
PrinterSettings ShowPrintSetupDialog();
void ShowPrintPreviewDialog();
}
}

View File

@ -0,0 +1,10 @@
using System;
using System.Drawing;
namespace GoldPrinter
{
public class ImportExcelArgs
{
public Icon ButtonIcon = null;
}
}

View File

@ -0,0 +1,6 @@
using System;
namespace GoldPrinter
{
public delegate void ImportExcelDelegate(object obj, ImportExcelArgs ev);
}

View File

@ -0,0 +1,846 @@
using System;
using System.Data;
using System.Drawing;
using System.Drawing.Printing;
using System.Windows.Forms;
namespace GoldPrinter
{
public class MisGoldPrinter : IDisposable
{
private const int CON_SPACE_TITLE_CAPTION = 5;
private const int CON_SPACE_CAPTION_TOP = 20;
private const int CON_SPACE_HEADER_BODY = 5;
private const int CON_SPACE_BODY_FOOTER = 5;
private int X;
private int Y;
private int Width;
private float Scale = 1f;
private int mCurrentPageIndex;
private int mCurrentRowIndex;
private Graphics mGraphics;
private Printer mPrinter;
private PrintDocument mPrintDocument;
private PrinterMargins mPrinterMargins;
private Sewing _sewing;
private bool _isOnlySingleColor = true;
public Color BackColor = Color.White;
private int _rowsPerPage = -1;
private bool _isSubTotalPerPage = false;
private string _subTotalColsList = "";
private bool _isSewingLine = false;
private bool _isPrinterMargins = false;
private GridBorderFlag _gridBorder = GridBorderFlag.Double;
private Title _title;
private Caption _caption;
private Top _top;
private Header _header;
private MultiHeader _multiHeader;
private Body _body;
protected Footer _footer;
private Bottom _bottom;
public Sewing Sewing
{
get
{
return this._sewing;
}
set
{
if (value != null)
{
this._sewing = value;
}
else
{
this._sewing.Margin = 0;
}
}
}
public string DocumentName
{
get
{
return this.mPrintDocument.DocumentName;
}
set
{
this.mPrintDocument.DocumentName = value;
}
}
public int RowsPerPage
{
get
{
return this._rowsPerPage;
}
set
{
this._rowsPerPage = value;
}
}
public bool IsSubTotalPerPage
{
get
{
return this._isSubTotalPerPage;
}
set
{
this._isSubTotalPerPage = value;
}
}
public string SubTotalColsList
{
get
{
return this._subTotalColsList;
}
set
{
this._subTotalColsList = value;
}
}
public bool IsSewingLine
{
get
{
return this._isSewingLine;
}
set
{
this._isSewingLine = value;
}
}
public bool IsPrinterMargins
{
get
{
return this._isPrinterMargins;
}
set
{
this._isPrinterMargins = value;
}
}
public GridBorderFlag GridBorder
{
get
{
return this._gridBorder;
}
set
{
this._gridBorder = value;
}
}
public object Title
{
get
{
return this._title;
}
set
{
if (value != null)
{
if (value.GetType().ToString() == "System.String")
{
if (this._title == null)
{
this._title = new Title();
}
this._title.Text = (string)value;
}
else if (value.GetType().ToString() == "GoldPrinter.Title")
{
this._title = (Title)value;
}
}
}
}
public object Caption
{
get
{
return this._caption;
}
set
{
if (value != null)
{
if (value.GetType().ToString() == "System.String")
{
if (this._caption == null)
{
this._caption = new Caption();
}
this._caption.Text = (string)value;
}
else if (value.GetType().ToString() == "GoldPrinter.Caption")
{
this._caption = (Caption)value;
}
}
}
}
public object Top
{
get
{
return this._top;
}
set
{
if (value != null)
{
if (value.GetType().ToString() == "System.String" || value.GetType().ToString() == "System.String[]")
{
if (this._top == null)
{
this._top = new Top();
}
this._top.DataSource = value;
}
else if (value.GetType().ToString() == "GoldPrinter.Top")
{
this._top = (Top)value;
}
}
}
}
public object Bottom
{
get
{
return this._bottom;
}
set
{
if (value != null)
{
if (value.GetType().ToString() == "System.String" || value.GetType().ToString() == "System.String[]")
{
if (this._bottom == null)
{
this._bottom = new Bottom();
}
this._bottom.DataSource = (string)value;
}
else if (value.GetType().ToString() == "GoldPrinter.Bottom")
{
this._bottom = (Bottom)value;
}
}
}
}
public object Header
{
get
{
return this._header;
}
set
{
if (value != null)
{
if (value.GetType().ToString() == "System.String[]" || value.GetType().ToString() == "System.String[,]" || value.GetType().ToString() == "System.Data.DataTable")
{
if (this._header == null)
{
this._header = new Header();
}
this._header.DataSource = value;
}
else if (value.GetType().ToString() == "GoldPrinter.Header")
{
this._header = (Header)value;
}
}
}
}
public object Footer
{
get
{
return this._footer;
}
set
{
if (value != null)
{
if (value.GetType().ToString() == "System.String[]" || value.GetType().ToString() == "System.String[,]" || value.GetType().ToString() == "System.Data.DataTable")
{
if (this._footer == null)
{
this._footer = new Footer();
}
this._footer.DataSource = value;
}
else if (value.GetType().ToString() == "GoldPrinter.Footer")
{
this._footer = (Footer)value;
}
}
}
}
public object MultiHeader
{
get
{
return this._multiHeader;
}
set
{
if (value != null)
{
if (value.GetType().ToString() == "System.String[]" || value.GetType().ToString() == "System.String[,]" || value.GetType().ToString() == "System.Data.DataTable")
{
if (this._multiHeader == null)
{
this._multiHeader = new MultiHeader();
}
this._multiHeader.DataSource = value;
}
else if (value.GetType().ToString() == "GoldPrinter.MultiHeader")
{
this._multiHeader = (MultiHeader)value;
}
}
}
}
public object Body
{
get
{
return this._body;
}
set
{
if (value != null)
{
if (value.GetType().ToString() == "System.String[]" || value.GetType().ToString() == "System.String[,]" || value.GetType().ToString() == "System.Data.DataTable")
{
if (this._body == null)
{
this._body = new Body();
}
this._body.DataSource = value;
}
else if (value.GetType().ToString() == "GoldPrinter.Body")
{
this._body = (Body)value;
}
}
}
}
public object DataSource
{
get
{
return this._body.DataSource;
}
set
{
this._body.DataSource = value;
}
}
public MisGoldPrinter() : this(false)
{
}
public MisGoldPrinter(bool p_IsLandscape)
{
PrinterSingleton.Reset();
this.mCurrentPageIndex = 1;
this.mCurrentRowIndex = 0;
this.mPrintDocument = PrinterSingleton.PrintDocument;
this.mPrintDocument.DefaultPageSettings.Landscape = p_IsLandscape;
this.mPrinterMargins = PrinterSingleton.PrinterMargins;
this.mPrintDocument.DocumentName = "MIS金质打印通欢迎使用";
this._sewing = new Sewing(30, SewingDirectionFlag.Left);
this.mPrinter = new Printer();
this._body = new Body();
}
public virtual void Dispose()
{
try
{
this.mGraphics.Dispose();
this.mPrintDocument.Dispose();
}
catch
{
}
}
public PageSettings PageSetup()
{
PrinterPageSetting printerPageSetting = new PrinterPageSetting(this.mPrintDocument);
printerPageSetting.PrintPage += new PrintPageDelegate(this.PrintPageEventHandler);
PageSettings defaultPageSettings = this.mPrintDocument.DefaultPageSettings;
PageSettings pageSettings = printerPageSetting.ShowPageSetupDialog();
if (defaultPageSettings != pageSettings)
{
PrinterSingleton.PrintDocument = this.mPrintDocument;
this.mPrinterMargins = new PrinterMargins(this.mPrintDocument);
PrinterSingleton.PrinterMargins = this.mPrinterMargins;
}
return pageSettings;
}
public PrinterSettings Print()
{
this.mCurrentPageIndex = 1;
this.mCurrentRowIndex = 0;
PrinterPageSetting printerPageSetting = new PrinterPageSetting(this.mPrintDocument);
printerPageSetting.PrintPage += new PrintPageDelegate(this.PrintPageEventHandler);
return printerPageSetting.ShowPrintSetupDialog();
}
public void Preview()
{
this.mCurrentPageIndex = 1;
this.mCurrentRowIndex = 0;
PrinterPageSetting printerPageSetting = new PrinterPageSetting(this.mPrintDocument);
printerPageSetting.PrintPage += new PrintPageDelegate(this.PrintPageEventHandler);
printerPageSetting.ImportExcelValue = new ImportExcelDelegate(this.ImportExcelMethodHandler);
printerPageSetting.ShowPrintPreviewDialog();
}
public void ImportExcelMethodHandler(object obj, ImportExcelArgs ev)
{
ExcelAccess excelAccess = new ExcelAccess();
excelAccess.Open();
excelAccess.MergeCells(1, 1, 1, this._body.Cols);
excelAccess.SetFont(1, 1, 1, this._body.Cols, this._title.Font);
excelAccess.SetCellText(1, 1, 1, this._body.Cols, this._title.Text);
excelAccess.SetCellText((DataTable)this.DataSource, 3, 1, true);
FileDialog fileDialog = new SaveFileDialog();
fileDialog.AddExtension = true;
fileDialog.DefaultExt = ".xls";
fileDialog.Title = "保存到Excel文件";
fileDialog.Filter = "Microsoft Office Excel 工作簿(*.xls)|*.xls|模板(*.xlt)|*.xlt";
if (fileDialog.ShowDialog() == DialogResult.OK)
{
if (excelAccess.SaveAs(fileDialog.FileName, true))
{
MessageBox.Show("数据成功保存到Excel文件", "GoldPrinter", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
}
}
fileDialog.Dispose();
excelAccess.Close();
}
private void PrintPageEventHandler(object obj, PrintPageEventArgs ev)
{
Graphics graphics = ev.Graphics;
this.mGraphics = graphics;
try
{
bool flag = this.Draw(graphics);
if (flag)
{
ev.HasMorePages = true;
this.mCurrentPageIndex++;
}
else
{
ev.HasMorePages = false;
this.mCurrentPageIndex = 1;
this.mCurrentRowIndex = 0;
}
}
catch (Exception var_2_55)
{
}
}
private void OutObject(Printer outer)
{
if (outer != null)
{
outer.Graphics = this.mGraphics;
outer.Rectangle = new Rectangle(this.X, this.Y, this.Width, outer.Height);
if (this._isOnlySingleColor)
{
outer.Pen = Pens.Black;
outer.Brush = Brushes.Black;
}
outer.Draw();
this.Y += outer.Rectangle.Height;
}
}
private bool Draw(Graphics g)
{
bool flag = false;
if (this._body.Rows < 0)
{
throw new Exception("打印主要网格不能为空请用Body设置");
}
this.mPrinter.Graphics = g;
this.mPrinter.PrintDocument = this.mPrintDocument;
this.mPrinter.Sewing = this.Sewing;
this.mPrinter.PrinterMargins = this.mPrinterMargins;
this.Y = this.mPrinter.PrinterMargins.Top;
this.X = this.mPrinter.PrinterMargins.Left;
this.Width = this.mPrinter.PrinterMargins.Width;
this.DrawPrinterMargins(this.mPrinter);
this.DrawSewing(this.mPrinter);
if (this._title != null && (this.mCurrentPageIndex == 1 || this._title.IsDrawAllPage))
{
this._title.PrinterMargins = this.mPrinterMargins;
this.OutObject(this._title);
}
if (this._caption != null && (this.mCurrentPageIndex == 1 || this._caption.IsDrawAllPage))
{
this._caption.MoveY = 0;
if (this._title != null && (this.mCurrentPageIndex == 1 || this._title.IsDrawAllPage))
{
this._caption.MoveY = this._title.Height + 5;
}
this._caption.PrinterMargins = this.mPrinterMargins;
this.OutObject(this._caption);
}
if (this._title != null || this._caption != null)
{
this.Y += 20;
}
int num = 0;
int i;
if (!this._body.IsAverageColsWidth)
{
for (i = 0; i < this._body.ColsWidth.Length; i++)
{
num += this._body.ColsWidth[i];
}
if (num > this.mPrinterMargins.Width)
{
this.Scale = (float)(this.mPrinterMargins.Width / num);
}
else
{
this.Width = num;
this.X += (this.mPrinterMargins.Width - this.Width) / 2;
}
}
if (this._top != null && (this.mCurrentPageIndex == 1 || this._top.IsDrawAllPage))
{
this.OutObject(this._top);
}
if (this._header != null && (this.mCurrentPageIndex == 1 || this._header.IsDrawAllPage))
{
this.OutObject(this._header);
}
if ((this._top != null || this._header != null) && (this.mCurrentPageIndex == 1 || (this._top != null && this._top.IsDrawAllPage) || (this._header != null && this._header.IsDrawAllPage)))
{
this.Y += 5;
}
if (this._multiHeader != null && (this.mCurrentPageIndex == 1 || this._multiHeader.IsDrawAllPage))
{
this.OutObject(this._multiHeader);
}
float num2 = (float)(this.mPrinter.PrinterMargins.Height - (this.Y - this.mPrinter.PrinterMargins.Top));
if (this._footer != null && this._footer.IsDrawAllPage)
{
num2 -= (float)this._footer.Height;
}
if (this._bottom != null && this._bottom.IsDrawAllPage)
{
num2 -= (float)this._bottom.Height;
}
if (num2 < 0f)
{
throw new Exception("预留给打印主要网格的空间太小,请适当调整!");
}
int num3 = (int)(num2 / (float)this._body.RowHeight);
if (this.RowsPerPage > 0 && this.RowsPerPage < num3)
{
num3 = this.RowsPerPage;
}
if (this.IsSubTotalPerPage)
{
num3--;
}
Body body;
if (this.RowsPerPage > 0 && this.RowsPerPage < num3)
{
body = new Body(num3, this._body.Cols);
}
else
{
if (num3 > this._body.Rows - this.mCurrentRowIndex)
{
num3 = this._body.Rows - this.mCurrentRowIndex;
}
body = new Body(num3, this._body.Cols);
}
string[,] array = new string[num3, this._body.Cols];
i = 0;
while (i < num3 && this.mCurrentRowIndex < this._body.Rows)
{
for (int j = 0; j < this._body.Cols; j++)
{
array[i, j] = this._body.GetText(this.mCurrentRowIndex, j);
}
this.mCurrentRowIndex++;
i++;
}
body.GridText = array;
body.ColsAlignString = this._body.ColsAlignString;
body.ColsWidth = this._body.ColsWidth;
body.IsAverageColsWidth = this._body.IsAverageColsWidth;
body.Font = (Font)this._body.Font.Clone();
this.OutObject(body);
if (this.mCurrentRowIndex < this._body.Rows)
{
flag = true;
}
if (this._isSubTotalPerPage && this._subTotalColsList != "")
{
try
{
MultiHeader multiHeader = new MultiHeader(1, this._body.Cols);
multiHeader.ColsWidth = this._body.ColsWidth;
multiHeader.Graphics = g;
multiHeader.PrintDocument = this.mPrintDocument;
multiHeader.Sewing = this._sewing;
multiHeader.Rectangle = new Rectangle(this.X, this.Y, this.Width, multiHeader.Height);
multiHeader.SetText(0, 0, "本页小计");
multiHeader.SetText(0, 1, "本页小计");
string[] array2 = this._subTotalColsList.Split(new char[]
{
';'
});
double num4 = 0.0;
for (i = 0; i < array2.Length; i++)
{
int num5 = int.Parse(array2[i]);
for (int j = 0; j < array.GetLength(0); j++)
{
num4 += double.Parse(array[j, num5]);
}
multiHeader.SetText(0, num5, num4.ToString());
num4 = 0.0;
}
multiHeader.Draw();
this.Y += multiHeader.Height;
}
catch
{
}
}
if ((this._footer != null || this._bottom != null) && (this.mCurrentPageIndex == 1 || (this._top != null && this._top.IsDrawAllPage) || (this._header != null && this._header.IsDrawAllPage)))
{
this.Y += 5;
}
if (this._footer != null)
{
if (!flag || this._footer.IsDrawAllPage)
{
if (this._footer.IsDrawAllPage)
{
this.OutObject(this._footer);
}
}
}
if (this._bottom != null)
{
if (!flag || this._bottom.IsDrawAllPage)
{
if (this._bottom.IsDrawAllPage)
{
this.OutObject(this._bottom);
}
else
{
num2 = (float)(this.mPrinter.PrinterMargins.Height - (this.Y - this.mPrinter.PrinterMargins.Top));
if (num2 < (float)this._bottom.Height)
{
flag = true;
}
else
{
this.OutObject(this._bottom);
}
}
}
}
this.DrawBorder(g, this._multiHeader, body);
body.Dispose();
body = null;
return flag;
}
private void DrawPrinterMargins(Printer printer)
{
if (this.IsPrinterMargins)
{
printer.DrawPrinterMargins();
}
}
private void DrawSewing(Printer printer)
{
if (this.IsSewingLine && this.Sewing.Margin > 0)
{
if (this.Sewing.LineLen <= 0)
{
if (this.Sewing.SewingDirection == SewingDirectionFlag.Left)
{
this.Sewing.LineLen = printer.PageHeight;
}
else if (this.Sewing.SewingDirection == SewingDirectionFlag.Top)
{
this.Sewing.LineLen = printer.PageWidth;
}
}
printer.Sewing = this.Sewing;
printer.DrawSewing();
}
}
private void DrawBorder(Graphics g, MultiHeader multiHeader, Body body)
{
int width = body.Rectangle.Width;
int num = body.Rectangle.Height;
int x;
int y;
if (multiHeader != null)
{
x = multiHeader.Rectangle.X;
y = multiHeader.Rectangle.Y;
num += multiHeader.Rectangle.Height;
}
else
{
x = body.Rectangle.X;
y = body.Rectangle.Y;
}
if (this.IsSubTotalPerPage)
{
MultiHeader multiHeader2 = new MultiHeader(1, 1);
num += multiHeader2.RowHeight;
}
Rectangle rectangle = new Rectangle(x, y, width, num);
Pen pen = new Pen(Color.Black, 1f);
DrawRectangle drawRectangle = new DrawRectangle();
drawRectangle.Graphics = g;
drawRectangle.Rectangle = rectangle;
drawRectangle.Pen = pen;
switch (this.GridBorder)
{
case GridBorderFlag.Single:
drawRectangle.Draw();
break;
case GridBorderFlag.SingleBold:
drawRectangle.Pen.Width = 2f;
drawRectangle.Draw();
if (multiHeader != null)
{
drawRectangle.Rectangle = body.Rectangle;
drawRectangle.DrawTopLine();
}
break;
case GridBorderFlag.Double:
drawRectangle.Draw();
rectangle = new Rectangle(x - 2, y - 2, width + 4, num + 4);
drawRectangle.Rectangle = rectangle;
drawRectangle.Draw();
break;
case GridBorderFlag.DoubleBold:
drawRectangle.Draw();
rectangle = new Rectangle(x - 2, y - 2, width + 4, num + 4);
drawRectangle.Rectangle = rectangle;
drawRectangle.Pen.Width = 2f;
drawRectangle.Draw();
break;
}
}
private void AddSewingNonePrintArea()
{
if (this.Sewing.SewingDirection == SewingDirectionFlag.Left)
{
this.mPrinterMargins.Left += this.Sewing.Margin;
this.mPrinterMargins.Width -= this.Sewing.Margin;
}
else if (this.Sewing.SewingDirection == SewingDirectionFlag.Top)
{
this.mPrinterMargins.Top += this.Sewing.Margin;
this.mPrinterMargins.Height -= this.Sewing.Margin;
}
}
private void WriteMetricsToConsole(PrintPageEventArgs ev)
{
Graphics graphics = ev.Graphics;
Console.WriteLine("*****Information about the printer*****");
Console.WriteLine("纸张的大小 ev.PageSettings.PaperSize:" + ev.PageSettings.PaperSize);
Console.WriteLine("打印分辨率 ev.PageSettings.PrinterResolution:" + ev.PageSettings.PrinterResolution);
Console.WriteLine("旋转的角度 ev.PageSettings.PrinterSettings.LandscapeAngle" + ev.PageSettings.PrinterSettings.LandscapeAngle);
Console.WriteLine("");
Console.WriteLine("*****Information about the page*****");
Console.WriteLine("页面的大小 ev.PageSettings.Bounds:" + ev.PageSettings.Bounds);
Console.WriteLine("页面(同上) ev.PageBounds:" + ev.PageBounds);
Console.WriteLine("页面的边距 ev.PageSettings.Margins.:" + ev.PageSettings.Margins);
Console.WriteLine("页面的边距 ev.MarginBounds:" + ev.MarginBounds);
Console.WriteLine("水平分辨率 ev.Graphics.DpiX:" + ev.Graphics.DpiX);
Console.WriteLine("垂直分辨率 ev.Graphics.DpiY:" + ev.Graphics.DpiY);
ev.Graphics.SetClip(ev.PageBounds);
Console.WriteLine("ev.Graphics.VisibleClipBounds:" + ev.Graphics.VisibleClipBounds);
SizeF sizeF = new SizeF(ev.Graphics.VisibleClipBounds.Width * ev.Graphics.DpiX / 100f, ev.Graphics.VisibleClipBounds.Height * ev.Graphics.DpiY / 100f);
Console.WriteLine("drawing Surface Size in Pixels" + sizeF);
}
}
}

View File

@ -0,0 +1,119 @@
using System;
using System.Drawing;
namespace GoldPrinter
{
public class MultiHeader : Header
{
private const int CONST_MAX_ROWS = 3;
private bool _isDrawDiagonalLine;
private float _DiagonalLineRows;
public bool IsDrawDiagonalLine
{
get
{
return this._isDrawDiagonalLine;
}
set
{
this._isDrawDiagonalLine = value;
}
}
public float DiagonalLineRows
{
get
{
return this._DiagonalLineRows;
}
set
{
this._DiagonalLineRows = value;
}
}
public string ColsAlign
{
get
{
return this.mdrawGrid.ColsAlignString;
}
set
{
this.mdrawGrid.ColsAlignString = value;
}
}
public MultiHeader()
{
this.IsDrawAllPage = true;
this.mdrawGrid.AlignMent = AlignFlag.Center;
this.mdrawGrid.Border = GridBorderFlag.Single;
this.mdrawGrid.Line = GridLineFlag.Both;
base.IsAverageColsWidth = false;
this._isDrawDiagonalLine = false;
this._DiagonalLineRows = 2f;
this.mdrawGrid.Merge = GridMergeFlag.Any;
this.Font = new Font("宋体", 12f, FontStyle.Bold);
this.mdrawGrid.PreferredRowHeight = this.Font.Height + 10;
}
protected override int SetMaxRows()
{
return 3;
}
public void SetMergeTextOnRowSel(int row, int startCol, int endCol, string text)
{
this.mdrawGrid.SetTextOnRowSel(row, startCol, endCol, text);
}
public void SetMergeTextOnColSel(int col, int startRow, int endRow, string text)
{
this.mdrawGrid.SetTextOnColSel(col, startRow, endRow, text);
}
public MultiHeader(int rows, int cols) : this()
{
base.Initialize(rows, cols);
string text = "";
for (int i = 0; i < cols; i++)
{
text += "C";
}
this.mdrawGrid.ColsAlignString = text;
}
protected void DrawDiagonalLine(float rows)
{
try
{
int x = this.mdrawGrid.Rectangle.X;
int y = this.mdrawGrid.Rectangle.Y;
int x2 = x + this.mdrawGrid.ColsWidth[0];
int y2 = y + (int)((float)this.mdrawGrid.PreferredRowHeight * this._DiagonalLineRows);
base.Graphics.SetClip(new Rectangle(x, y, this.mdrawGrid.ColsWidth[0], this.mdrawGrid.PreferredRowHeight * this.mdrawGrid.Rows));
base.Graphics.DrawLine(Pens.Black, x, y, x2, y2);
}
catch (Exception var_4_A2)
{
}
finally
{
base.Graphics.ResetClip();
}
}
public override void Draw()
{
base.Draw();
if (this._isDrawDiagonalLine)
{
this.DrawDiagonalLine(this._DiagonalLineRows);
}
}
}
}

View File

@ -0,0 +1,171 @@
using System;
using System.Drawing;
namespace GoldPrinter
{
public class Outer : Printer, IDisposable
{
private bool _IsAverageColsWidth;
protected DrawGrid mdrawGrid;
protected bool mblnHadInitialized;
public bool IsAverageColsWidth
{
get
{
return this._IsAverageColsWidth;
}
set
{
this._IsAverageColsWidth = value;
}
}
public object DataSource
{
get
{
return this.mdrawGrid.DataSource;
}
set
{
this.mdrawGrid.DataSource = value;
if (this.DataSource.GetType().ToString() == "System.String[]" || this.DataSource.GetType().ToString() == "System.String[,]" || this.DataSource.GetType().ToString() == "System.Data.DataTable")
{
this.mblnHadInitialized = true;
}
}
}
public string[,] Text
{
get
{
return this.mdrawGrid.GridText;
}
set
{
this.mdrawGrid.GridText = value;
this.mblnHadInitialized = true;
}
}
public bool CanDraw
{
get
{
return this.mblnHadInitialized;
}
}
public int RowHeight
{
get
{
return this.mdrawGrid.PreferredRowHeight;
}
set
{
this.mdrawGrid.PreferredRowHeight = value;
}
}
public int Rows
{
get
{
return this.mdrawGrid.Rows;
}
}
public int Cols
{
get
{
return this.mdrawGrid.Cols;
}
}
public int[] ColsWidth
{
get
{
return this.mdrawGrid.ColsWidth;
}
set
{
this.mdrawGrid.ColsWidth = value;
}
}
public override int Height
{
get
{
return this.mdrawGrid.Rows * this.mdrawGrid.PreferredRowHeight;
}
}
public Outer()
{
this._IsAverageColsWidth = true;
this.mblnHadInitialized = false;
this.IsDrawAllPage = false;
this.mdrawGrid = new DrawGrid();
this.mdrawGrid.AlignMent = AlignFlag.Left;
this.mdrawGrid.ColsAlignString = "";
this.mdrawGrid.Border = GridBorderFlag.None;
this.mdrawGrid.Line = GridLineFlag.None;
this.mdrawGrid.Merge = GridMergeFlag.None;
this.Font = new Font("宋体", 11f);
this.mdrawGrid.PreferredRowHeight = this.Font.Height;
this.mdrawGrid.Initialize(0, 0);
}
public virtual void Initialize(int rows, int cols)
{
this.mblnHadInitialized = true;
this.mdrawGrid.Initialize(rows, cols);
}
public virtual void SetText(int row, int col, string text)
{
this.mdrawGrid.SetText(row, col, text);
}
public virtual void SetText(char rowSplit, char colSplit, string text)
{
this.mdrawGrid.SetText((int)rowSplit, (int)colSplit, text);
}
public virtual string GetText(int row, int col)
{
return this.mdrawGrid.GetText(row, col);
}
public override void Draw()
{
if (this.mblnHadInitialized)
{
base.Draw();
this.mdrawGrid.Rectangle = new Rectangle(base.Rectangle.X + base.MoveX, base.Rectangle.Y + base.MoveY, base.Rectangle.Width, base.Rectangle.Height);
this.mdrawGrid.Graphics = base.Graphics;
if (this._IsAverageColsWidth)
{
this.mdrawGrid.Width = this.mdrawGrid.Rectangle.Width;
this.mdrawGrid.ColsWidth = this.mdrawGrid.GetAverageColsWidth();
}
this.mdrawGrid.Draw();
return;
}
throw new Exception("对象的行列数还未初始请用Initialize进行操作");
}
public override void Dispose()
{
this.mdrawGrid.Dispose();
}
}
}

View File

@ -0,0 +1,10 @@
using System;
namespace GoldPrinter
{
public enum PrintModeFlag
{
Win,
Web
}
}

View File

@ -0,0 +1,7 @@
using System;
using System.Drawing.Printing;
namespace GoldPrinter
{
public delegate void PrintPageDelegate(object obj, PrintPageEventArgs ev);
}

View File

@ -0,0 +1,175 @@
using System;
using System.Drawing;
namespace GoldPrinter
{
public class Printer : PrinterBase
{
private Sewing _sewing;
private Font _font;
private bool _isDrawAllPage;
private int _height;
private int _MoveX;
private int _MoveY;
public virtual Sewing Sewing
{
get
{
return this._sewing;
}
set
{
if (value != null)
{
this._sewing = value;
}
}
}
public virtual Font Font
{
get
{
return this._font;
}
set
{
if (value != null)
{
this._font = value;
}
}
}
public virtual bool IsDrawAllPage
{
get
{
return this._isDrawAllPage;
}
set
{
this._isDrawAllPage = value;
}
}
public virtual int Height
{
get
{
return this._height;
}
set
{
this._height = value;
if (this._height < 0)
{
this._height = 0;
}
}
}
public int MoveX
{
get
{
return this._MoveX;
}
set
{
this._MoveX = value;
}
}
public int MoveY
{
get
{
return this._MoveY;
}
set
{
this._MoveY = value;
}
}
public Printer()
{
this._sewing = new Sewing();
this._font = new Font("宋体", 10f);
this._isDrawAllPage = false;
this._height = 0;
this._MoveX = 0;
this._MoveY = 0;
}
public int TextWidth(string text)
{
return (int)base.Graphics.MeasureString(text, this.Font, base.PrinterMargins.Width).Width;
}
public int TextHeight(string text)
{
return (int)base.Graphics.MeasureString(text, this.Font, base.PrinterMargins.Width).Height;
}
public int TextHeight()
{
return this.Font.Height;
}
public virtual void DrawPrinterMargins()
{
this.CheckGraphics();
Rectangle rect = new Rectangle(base.PrinterMargins.Left, base.PrinterMargins.Top, base.PrinterMargins.Width, base.PrinterMargins.Height);
base.Graphics.DrawRectangle(base.Pen, rect);
}
public virtual void DrawSewing()
{
this.CheckGraphics();
this.Sewing.LineLen = this.GetSewingLineLength();
this.Sewing.Draw(base.Graphics);
}
private int GetSewingLineLength()
{
int result = 0;
if (this.Sewing.SewingDirection == SewingDirectionFlag.Left)
{
result = base.PageHeight;
}
else if (this.Sewing.SewingDirection == SewingDirectionFlag.Top)
{
result = base.PageWidth;
}
return result;
}
public override void Draw()
{
this.CheckGraphics();
}
protected virtual void CheckGraphics()
{
if (base.Graphics == null)
{
throw new Exception("绘图表面不能为空请设置Graphics属性");
}
}
public override void Dispose()
{
base.Dispose();
this._sewing.Dispose();
this._font.Dispose();
}
}
}

View File

@ -0,0 +1,130 @@
using System;
using System.Drawing.Printing;
namespace GoldPrinter
{
public abstract class PrinterBase : DrawBase
{
private PrintDocument _printDocument;
private PrinterMargins _printerMargins;
private int _pageWidth;
private int _pageHeight;
private int _leftMargin;
private int _rightMargin;
private int _topMargin;
private int _bottomMargin;
public PrintDocument PrintDocument
{
get
{
return this._printDocument;
}
set
{
if (value != null)
{
this._printDocument = value;
}
}
}
public PrinterMargins PrinterMargins
{
get
{
return this._printerMargins;
}
set
{
if (value != null)
{
this._printerMargins = value;
this.SetPageInfo();
}
}
}
public int PageWidth
{
get
{
return this._pageWidth;
}
}
public int PageHeight
{
get
{
return this._pageHeight;
}
}
public int LeftMargin
{
get
{
return this._leftMargin;
}
}
public int RightMargin
{
get
{
return this._rightMargin;
}
}
public int TopMargin
{
get
{
return this._topMargin;
}
}
public int BottomMargin
{
get
{
return this._bottomMargin;
}
}
public PrinterBase()
{
this._printDocument = PrinterSingleton.PrintDocument;
this._printerMargins = PrinterSingleton.PrinterMargins;
this.SetPageInfo();
}
public void CalculatePageInfo()
{
this.PrinterMargins = new PrinterMargins(this.PrintDocument);
this.SetPageInfo();
}
private void SetPageInfo()
{
this._leftMargin = this.PrinterMargins.Left;
this._topMargin = this.PrinterMargins.Top;
this._rightMargin = this.PrinterMargins.Right;
this._bottomMargin = this.PrinterMargins.Bottom;
this._pageWidth = this.PrinterMargins.Width + this._leftMargin + this._rightMargin;
this._pageHeight = this.PrinterMargins.Height + this._topMargin + this._bottomMargin;
}
private void AddNonePrintArea()
{
}
}
}

View File

@ -0,0 +1,132 @@
using System;
using System.Drawing.Printing;
namespace GoldPrinter
{
public class PrinterMargins : Margins
{
private int _width;
private int _height;
private int _X1;
private int _X2;
private int _Y1;
private int _Y2;
public int Width
{
get
{
return this._width;
}
set
{
this._width = value;
}
}
public int Height
{
get
{
return this._height;
}
set
{
this._height = value;
}
}
public int X1
{
get
{
return this._X1;
}
}
public int X2
{
get
{
return this._X2;
}
}
public int Y1
{
get
{
return this._Y1;
}
}
public int Y2
{
get
{
return this._Y2;
}
}
public PrinterMargins() : this(1, 1, 1, 1, 0, 0)
{
}
public PrinterMargins(int left, int right, int top, int bottom, int width, int height) : base(left, right, top, bottom)
{
this._width = width;
this._height = height;
this.Calculate();
}
public PrinterMargins(PrintDocument printDocument)
{
PrinterMargins printerMargins = new PrinterMargins();
printerMargins = this.GetPrinterMargins(printDocument);
base.Left = printerMargins.Left;
base.Right = printerMargins.Right;
base.Top = printerMargins.Top;
base.Bottom = printerMargins.Bottom;
this.Width = printerMargins.Width;
this.Height = printerMargins.Height;
this.Calculate();
}
private PrinterMargins GetPrinterMargins(PrintDocument printDocument)
{
int left = printDocument.DefaultPageSettings.Margins.Left;
int right = printDocument.DefaultPageSettings.Margins.Right;
int top = printDocument.DefaultPageSettings.Margins.Top;
int bottom = printDocument.DefaultPageSettings.Margins.Bottom;
int num = printDocument.DefaultPageSettings.PaperSize.Width;
int num2 = printDocument.DefaultPageSettings.PaperSize.Height;
if (printDocument.DefaultPageSettings.Landscape)
{
this.Swap(ref num, ref num2);
}
num = num - left - right;
num2 = num2 - top - bottom;
return new PrinterMargins(left, right, top, bottom, num, num2);
}
private void Swap(ref int ValA, ref int ValB)
{
int num = ValA;
ValA = ValB;
ValB = num;
}
private void Calculate()
{
this._X1 = base.Left;
this._X2 = base.Left + this._width;
this._Y1 = base.Top;
this._Y2 = base.Top + this._height;
}
}
}

View File

@ -0,0 +1,121 @@
using System;
using System.Configuration;
using System.Drawing.Printing;
namespace GoldPrinter
{
public class PrinterPageSetting
{
private IPrinterPageSetting _printerPageSetting;
private PrintModeFlag _printModeFlag;
public event PrintPageDelegate PrintPage
{
add
{
this._printerPageSetting.PrintPage += new PrintPageDelegate(value.Invoke);
}
remove
{
this._printerPageSetting.PrintPage -= new PrintPageDelegate(value.Invoke);
}
}
public PrintModeFlag PrintMode
{
get
{
return this._printModeFlag;
}
set
{
this._printModeFlag = value;
if (this._printModeFlag == PrintModeFlag.Win)
{
this._printerPageSetting = new WinPrinterPageSetting();
}
else if (this._printModeFlag == PrintModeFlag.Web)
{
this._printerPageSetting = new WebPrinterPageSetting();
}
}
}
public PrintDocument PrintDocument
{
get
{
return this._printerPageSetting.PrintDocument;
}
set
{
this._printerPageSetting.PrintDocument = value;
}
}
public PrintPageDelegate PrintPageValue
{
get
{
return this._printerPageSetting.PrintPageValue;
}
set
{
this._printerPageSetting.PrintPageValue = value;
}
}
public ImportExcelDelegate ImportExcelValue
{
get
{
return this._printerPageSetting.ImportExcelValue;
}
set
{
this._printerPageSetting.ImportExcelValue = value;
}
}
public PrinterPageSetting() : this(null)
{
}
public PrinterPageSetting(PrintDocument printDocument)
{
string text = ConfigurationSettings.AppSettings["PrintMode"];
if (text == null)
{
text = "Win";
}
if (text.ToUpper() == "WIN")
{
this.PrintMode = PrintModeFlag.Win;
}
else
{
this.PrintMode = PrintModeFlag.Web;
}
if (printDocument != null)
{
this._printerPageSetting.PrintDocument = printDocument;
}
}
public PageSettings ShowPageSetupDialog()
{
return this._printerPageSetting.ShowPageSetupDialog();
}
public PrinterSettings ShowPrintSetupDialog()
{
return this._printerPageSetting.ShowPrintSetupDialog();
}
public void ShowPrintPreviewDialog()
{
this._printerPageSetting.ShowPrintPreviewDialog();
}
}
}

View File

@ -0,0 +1,68 @@
using System;
using System.Drawing.Printing;
namespace GoldPrinter
{
public class PrinterSingleton
{
private static PrintDocument thePrintDocumentInstance = null;
private static PrinterMargins thePrinterMarginsInstance = null;
public static PrintDocument PrintDocument
{
get
{
return PrinterSingleton.GetPrintDocumentInstance();
}
set
{
PrinterSingleton.thePrintDocumentInstance = value;
}
}
public static PrinterMargins PrinterMargins
{
get
{
return PrinterSingleton.GetPrinterMarginsInstance();
}
set
{
PrinterSingleton.thePrinterMarginsInstance = value;
}
}
private PrinterSingleton()
{
}
public static void Reset()
{
if (PrinterSingleton.thePrintDocumentInstance != null)
{
PrinterSingleton.thePrintDocumentInstance.Dispose();
}
PrinterSingleton.thePrintDocumentInstance = null;
PrinterSingleton.thePrinterMarginsInstance = null;
}
private static PrintDocument GetPrintDocumentInstance()
{
if (PrinterSingleton.thePrintDocumentInstance == null)
{
PrinterSingleton.thePrintDocumentInstance = new PrintDocument();
}
return PrinterSingleton.thePrintDocumentInstance;
}
private static PrinterMargins GetPrinterMarginsInstance()
{
if (PrinterSingleton.thePrinterMarginsInstance == null)
{
PrinterSingleton.thePrinterMarginsInstance = new PrinterMargins(PrinterSingleton.GetPrintDocumentInstance());
}
return PrinterSingleton.thePrinterMarginsInstance;
}
}
}

View File

@ -0,0 +1,79 @@
using System;
using System.Drawing;
namespace GoldPrinter
{
public class PrinterTabStops : IDisposable
{
private int _cols;
public Font Font;
public Rectangle Rectangle;
private string _text;
private string _textConverted;
public int Cols
{
get
{
return this._cols;
}
set
{
this._cols = value;
}
}
public string Text
{
get
{
return this._text;
}
set
{
this._text = value;
string text = this._text;
this._textConverted = this.ConvertText(text);
}
}
public PrinterTabStops()
{
this.Font = new Font("宋体", 10f);
this.Rectangle = new Rectangle(0, 0, this.Font.Height, 100);
}
public PrinterTabStops(string text) : this()
{
this.Text = text;
}
public void Draw(Graphics g)
{
StringFormat stringFormat = new StringFormat();
stringFormat.FormatFlags = StringFormatFlags.NoWrap;
float num = (float)(this.Rectangle.Width / this._cols);
float[] array = new float[this._cols];
for (int i = 0; i < this._cols; i++)
{
array[i] = num;
}
stringFormat.SetTabStops(0f, array);
g.DrawString(this._textConverted, this.Font, Brushes.Black, this.Rectangle, stringFormat);
}
private string ConvertText(string text)
{
return text.Replace("|", "\t");
}
public void Dispose()
{
this.Font.Dispose();
}
}
}

View File

@ -0,0 +1,115 @@
using System;
using System.Drawing;
using System.Drawing.Drawing2D;
namespace GoldPrinter
{
public class Sewing : IDisposable
{
private SewingDirectionFlag _sewingDirection;
private int _margin;
private int _lineLength;
public SewingDirectionFlag SewingDirection
{
get
{
return this._sewingDirection;
}
set
{
this._sewingDirection = value;
}
}
public int Margin
{
get
{
return this._margin;
}
set
{
this._margin = value;
}
}
public int LineLen
{
get
{
return this._lineLength;
}
set
{
this._lineLength = value;
}
}
public Sewing()
{
this._margin = 0;
this._sewingDirection = SewingDirectionFlag.Left;
this._lineLength = 0;
}
public Sewing(int margin) : this(margin, SewingDirectionFlag.Left, 0)
{
}
public Sewing(int margin, int lineLength) : this(margin, SewingDirectionFlag.Left, lineLength)
{
}
public Sewing(int margin, SewingDirectionFlag sewingDirection) : this(margin, sewingDirection, 0)
{
}
public Sewing(int margin, SewingDirectionFlag sewingDirection, int lineLength)
{
this._margin = margin;
this._sewingDirection = sewingDirection;
this._lineLength = lineLength;
}
public virtual void Dispose()
{
}
public void Draw(Graphics g)
{
Font font = new Font("宋体", 8f);
string s = "装 订 线";
StringFormat stringFormat = new StringFormat();
stringFormat.Alignment = StringAlignment.Center;
int margin;
int num = margin = this._margin;
int lineLength;
int num2 = lineLength = this._lineLength;
Pen pen = new Pen(Color.Red);
pen.DashStyle = DashStyle.Dot;
if (this._sewingDirection == SewingDirectionFlag.Left)
{
g.DrawLine(pen, margin, 0, margin, lineLength);
stringFormat.FormatFlags = StringFormatFlags.DirectionVertical;
int num3 = (int)g.MeasureString("装", font).Width;
num3 /= 2;
Rectangle r = new Rectangle(margin - num3, 0, margin - num3, lineLength);
g.DrawString(s, font, Brushes.DodgerBlue, r, stringFormat);
}
else if (this._sewingDirection == SewingDirectionFlag.Top)
{
g.DrawLine(pen, 0, num, num2, num);
int num4 = (int)g.MeasureString("装", font).Height;
num4 /= 2;
Rectangle r = new Rectangle(0, num - num4, num2, num - num4);
g.DrawString(s, font, Brushes.DodgerBlue, r, stringFormat);
}
pen.Dispose();
font.Dispose();
stringFormat.Dispose();
}
}
}

View File

@ -0,0 +1,10 @@
using System;
namespace GoldPrinter
{
public enum SewingDirectionFlag
{
Left,
Top
}
}

View File

@ -0,0 +1,26 @@
using System;
namespace GoldPrinter
{
public class TimeDef
{
private static DateTime dt1;
private static DateTime dt2;
public static void Start()
{
TimeDef.dt1 = DateTime.Now;
Console.WriteLine("开始:" + TimeDef.dt1.ToString() + TimeDef.dt1.Millisecond.ToString());
}
public static void End()
{
TimeDef.dt2 = DateTime.Now;
Console.WriteLine("结束:" + TimeDef.dt2.ToString() + TimeDef.dt2.Millisecond.ToString());
TimeSpan timeSpan = TimeDef.dt2 - TimeDef.dt1;
Console.WriteLine("用时:" + timeSpan.TotalSeconds.ToString() + "秒");
Console.WriteLine("用时:" + timeSpan.TotalMilliseconds.ToString() + "毫秒");
}
}
}

View File

@ -0,0 +1,37 @@
using System;
using System.Drawing;
namespace GoldPrinter
{
public class Title : Caption
{
public Title()
{
this.IsDrawAllPage = true;
this.Font = new Font("黑体", 21f, FontStyle.Bold);
base.MaxRows = 2;
}
public Title(string text) : this()
{
base.Text = text;
}
public override void Draw()
{
base.Draw();
float num = (float)base.Rectangle.Width;
int num2 = base.Text.LastIndexOf("\n");
if (num2 > 0)
{
string text = base.Text.Substring(num2 + 1);
num = (float)base.TextWidth(text);
}
float num3 = ((float)base.PrinterMargins.Width - num) / 2f + (float)base.PrinterMargins.Left + (float)base.MoveX;
float num4 = (float)(base.Rectangle.Y + base.Rectangle.Height);
float x = num3 + num;
base.Graphics.DrawLine(base.Pen, num3, num4 - 4f, x, num4 - 4f);
base.Graphics.DrawLine(base.Pen, num3, num4 - 2f, x, num4 - 2f);
}
}
}

View File

@ -0,0 +1,126 @@
using System;
using System.Drawing;
namespace GoldPrinter
{
public class Top : Printer
{
protected DrawGrid mdrawGrid;
protected string _text;
protected object _dataSource;
public string Text
{
get
{
return this._text;
}
set
{
this._text = value;
this.SetText(this._text);
}
}
public object DataSource
{
get
{
return this._dataSource;
}
set
{
if (value != null)
{
if (value.GetType().ToString() == "System.String")
{
this.Text = (string)value;
}
else if (value.GetType().ToString() == "System.String[]")
{
string text = "";
string[] array = (string[])value;
if (array.Length > 0)
{
for (int i = 0; i < array.Length; i++)
{
text = text + "|" + array[i];
}
text = text.Substring(1);
this.Text = text;
}
else
{
this.Text = "";
}
}
}
else
{
this._dataSource = null;
}
}
}
public override int Height
{
get
{
return this.mdrawGrid.Rows * this.mdrawGrid.PreferredRowHeight;
}
}
public Top()
{
this.IsDrawAllPage = true;
this._text = "";
this.mdrawGrid = new DrawGrid();
this.mdrawGrid.ColsAlignString = "LCR";
this.mdrawGrid.Border = GridBorderFlag.None;
this.mdrawGrid.Line = GridLineFlag.None;
this.mdrawGrid.Merge = GridMergeFlag.None;
this.Font = new Font("宋体", 11f);
this.mdrawGrid.PreferredRowHeight = this.Font.Height;
this.mdrawGrid.Initialize(1, 3);
}
public virtual void SetText(string text)
{
this._text = text;
this.SetText(text, '|');
}
public virtual void SetText(string text, char split)
{
this._text = text;
string[] array = text.Split(new char[]
{
split
});
if (array.Length > 0)
{
this.mdrawGrid.SetText(0, 0, array[0]);
}
if (array.Length > 1)
{
this.mdrawGrid.SetText(0, 1, array[1]);
}
if (array.Length > 2)
{
this.mdrawGrid.SetText(0, 2, array[2]);
}
}
public override void Draw()
{
base.Draw();
this.mdrawGrid.Rectangle = new Rectangle(base.Rectangle.X + base.MoveX, base.Rectangle.Y + base.MoveY, base.Rectangle.Width, base.Rectangle.Height);
this.mdrawGrid.Graphics = base.Graphics;
this.mdrawGrid.Width = this.mdrawGrid.Rectangle.Width;
this.mdrawGrid.ColsWidth = this.mdrawGrid.GetAverageColsWidth();
this.mdrawGrid.Draw();
}
}
}

View File

@ -0,0 +1,11 @@
using System;
namespace GoldPrinter
{
public enum VAlignFlag
{
Top,
Middle,
Bottom
}
}

View File

@ -0,0 +1,57 @@
using System;
using System.Drawing.Printing;
namespace GoldPrinter
{
public class WebPrinterPageSetting : IPrinterPageSetting
{
public event PrintPageDelegate PrintPage;
public PrintDocument PrintDocument
{
get
{
return null;
}
set
{
}
}
public PrintPageDelegate PrintPageValue
{
get
{
return null;
}
set
{
}
}
public ImportExcelDelegate ImportExcelValue
{
get
{
return null;
}
set
{
}
}
public PageSettings ShowPageSetupDialog()
{
return null;
}
public PrinterSettings ShowPrintSetupDialog()
{
return null;
}
public void ShowPrintPreviewDialog()
{
}
}
}

View File

@ -0,0 +1,239 @@
using System;
using System.Drawing.Printing;
using System.Globalization;
using System.Windows.Forms;
namespace GoldPrinter
{
public class WinPrinterPageSetting : IPrinterPageSetting
{
private PrintPageDelegate _printPageValue;
private ImportExcelDelegate _importExcelValue;
private PrintDocument _printDocument;
public event PrintPageDelegate PrintPage
{
add
{
this._printDocument.PrintPage += new PrintPageEventHandler(value.Invoke);
this._printPageValue = value;
}
remove
{
this._printDocument.PrintPage -= new PrintPageEventHandler(value.Invoke);
this._printPageValue = null;
}
}
public PrintDocument PrintDocument
{
get
{
return this._printDocument;
}
set
{
this._printDocument = value;
}
}
public PrintPageDelegate PrintPageValue
{
get
{
return this._printPageValue;
}
set
{
this._printPageValue = value;
this._printDocument.PrintPage += new PrintPageEventHandler(this._printPageValue.Invoke);
}
}
public ImportExcelDelegate ImportExcelValue
{
get
{
return this._importExcelValue;
}
set
{
this._importExcelValue = value;
}
}
public WinPrinterPageSetting() : this(null)
{
}
public WinPrinterPageSetting(PrintDocument printDocument)
{
if (printDocument != null)
{
this._printDocument = printDocument;
}
else
{
this._printDocument = new PrintDocument();
}
}
public PageSettings ShowPageSetupDialog()
{
return this.ShowPageSetupDialog(this._printDocument);
}
public PrinterSettings ShowPrintSetupDialog()
{
return this.ShowPrintSetupDialog(this._printDocument);
}
public void ShowPrintPreviewDialog()
{
this.ShowPrintPreviewDialog(this._printDocument);
}
protected virtual PageSettings ShowPageSetupDialog(PrintDocument printDocument)
{
this.ThrowPrintDocumentNullException(printDocument);
PageSettings result = new PageSettings();
PageSetupDialog pageSetupDialog = new PageSetupDialog();
result = printDocument.DefaultPageSettings;
try
{
pageSetupDialog.Document = printDocument;
Margins margins = printDocument.DefaultPageSettings.Margins;
if (RegionInfo.CurrentRegion.IsMetric)
{
margins = PrinterUnitConvert.Convert(margins, PrinterUnit.Display, PrinterUnit.TenthsOfAMillimeter);
}
PageSettings pageSettings = (PageSettings)printDocument.DefaultPageSettings.Clone();
pageSetupDialog.PageSettings = pageSettings;
pageSetupDialog.PageSettings.Margins = margins;
DialogResult dialogResult = pageSetupDialog.ShowDialog();
if (dialogResult == DialogResult.OK)
{
result = pageSetupDialog.PageSettings;
printDocument.DefaultPageSettings = pageSetupDialog.PageSettings;
}
}
catch (InvalidPrinterException e)
{
this.ShowInvalidPrinterException(e);
}
catch (Exception ex)
{
this.ShowPrinterException(ex);
}
finally
{
pageSetupDialog.Dispose();
pageSetupDialog = null;
}
return result;
}
protected virtual PrinterSettings ShowPrintSetupDialog(PrintDocument printDocument)
{
this.ThrowPrintDocumentNullException(printDocument);
PrinterSettings result = new PrinterSettings();
PrintDialog printDialog = new PrintDialog();
try
{
printDialog.AllowSomePages = true;
printDialog.Document = printDocument;
DialogResult dialogResult = printDialog.ShowDialog();
if (dialogResult == DialogResult.OK)
{
result = printDialog.PrinterSettings;
printDocument.Print();
}
}
catch (InvalidPrinterException e)
{
this.ShowInvalidPrinterException(e);
}
catch (Exception ex)
{
this.ShowPrinterException(ex);
}
finally
{
printDialog.Dispose();
printDialog = null;
}
return result;
}
private void Excel_ButtonClick(object sender, ToolBarButtonClickEventArgs e)
{
ToolBarButton button = e.Button;
string toolTipText = button.ToolTipText;
if (toolTipText == "Import Excel" && this._importExcelValue != null)
{
this._importExcelValue.BeginInvoke(sender, null, null, null);
}
}
protected virtual void ShowPrintPreviewDialog(PrintDocument printDocument)
{
this.ThrowPrintDocumentNullException(printDocument);
PrintPreviewDialog printPreviewDialog = new PrintPreviewDialog();
printPreviewDialog.Text = printDocument.DocumentName;
printPreviewDialog.WindowState = FormWindowState.Maximized;
if (this._importExcelValue != null)
{
if (printPreviewDialog.Controls[1] is ToolBar)
{
ToolBar toolBar = (ToolBar)printPreviewDialog.Controls[1];
ToolBarButton toolBarButton = new ToolBarButton();
toolBarButton.ToolTipText = "Import Excel";
toolBarButton.ImageIndex = 2;
toolBar.ButtonClick += new ToolBarButtonClickEventHandler(this.Excel_ButtonClick);
toolBar.Buttons.Add(toolBarButton);
}
}
try
{
printPreviewDialog.Document = printDocument;
DialogResult dialogResult = printPreviewDialog.ShowDialog();
if (dialogResult == DialogResult.OK)
{
}
}
catch (InvalidPrinterException e)
{
this.ShowInvalidPrinterException(e);
}
catch (Exception ex)
{
this.ShowPrinterException(ex);
}
finally
{
printPreviewDialog.Dispose();
printPreviewDialog = null;
}
}
protected virtual void ThrowPrintDocumentNullException(PrintDocument printDocument)
{
if (printDocument == null)
{
throw new Exception("关联的打印文档不能为空!");
}
}
protected virtual void ShowInvalidPrinterException(InvalidPrinterException e)
{
MessageBox.Show("未安装打印机,请进入系统控制面版添加打印机!", "打印", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
}
protected virtual void ShowPrinterException(Exception ex)
{
MessageBox.Show(ex.Message, "打印", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
}
}
}

View File

@ -5,6 +5,7 @@ using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Windows.Forms;
using static System.Windows.Forms.VisualStyles.VisualStyleElement.ToolTip;
namespace DrawGraph
{
@ -259,9 +260,10 @@ namespace DrawGraph
}
myOpeRecord.DrugsListstr = DrugListstr;
if (myOpeRecord.BeforeDrugs == null || myOpeRecord.BeforeDrugs == "") myOpeRecord.BeforeDrugs ="无";
if (myOpeRecord.BeforeDrugs == null || myOpeRecord.BeforeDrugs == "") myOpeRecord.BeforeDrugs = "无";
template.SetObjValue(myOpeRecord, "OperationRecord.BeforeDrugs", myOpeRecord.BeforeDrugs, myOpeRecord.BeforeDrugs);
template.SetObjValue(myOpeRecord, "OperationRecord.AnalgesiaModeDrugs", myOpeRecord.AnalgesiaModeDrugs, myOpeRecord.AnalgesiaModeDrugs);
DrawDrugSapDose();
}
catch (Exception ex)
{
@ -321,18 +323,18 @@ namespace DrawGraph
DrugListstr.Add(string.Format("({0}){1} {2} {3}{4}{5}", i + 1, (temp.DrugBeginTime == temp.DrugEndTime) ? temp.DrugBeginTime.ToShortTimeString() : temp.DrugBeginTime.ToShortTimeString() + "->" + temp.DrugEndTime.ToShortTimeString(), temp.DrugName.Trim(), dose, "", temp.DrugChannel == null ? "" : " " + temp.DrugChannel.ToString()));
//DrugListstr.Append(" ");
}
private static void ListAddDrugs(List<string> DrugListstr, FactDrug temp)
{
string dose = "";
if (dose.Trim() != "") dose += " ";
dose += ((double)temp.Dosage).ToString();
if (temp.DosageUnit != null)
{
dose += temp.DosageUnit;
}
DrugListstr.Add(string.Format("{1} {2} {3}{4}{5}", "", (temp.DrugBeginTime == temp.DrugEndTime) ? temp.DrugBeginTime.ToShortTimeString() : temp.DrugBeginTime.ToShortTimeString() + "->" + temp.DrugEndTime.ToShortTimeString(), temp.DrugName.Trim(), dose, "", temp.DrugChannel == null ? "" : "<" + temp.DrugChannel.ToString() + ">"));
//DrugListstr.Append(" ");
}
//private static void ListAddDrugs(List<string> DrugListstr, FactDrug temp)
//{
// string dose = "";
// if (dose.Trim() != "") dose += " ";
// dose += ((double)temp.Dosage).ToString();
// if (temp.DosageUnit != null)
// {
// dose += temp.DosageUnit;
// }
// DrugListstr.Add(string.Format("{1} {2} {3}{4}{5}", "", (temp.DrugBeginTime == temp.DrugEndTime) ? temp.DrugBeginTime.ToShortTimeString() : temp.DrugBeginTime.ToShortTimeString() + "->" + temp.DrugEndTime.ToShortTimeString(), temp.DrugName.Trim(), dose, "", temp.DrugChannel == null ? "" : "<" + temp.DrugChannel.ToString() + ">"));
// //DrugListstr.Append(" ");
//}
private bool isSapDrugs(FactDrug record)
{
bool isSap = false;
@ -352,6 +354,71 @@ namespace DrawGraph
}
return isSap;
}
private void DrawDrugSapDose()
{
double x = template.GetPackObjectOTag<LinePackObj>("RemarkManage_LinePackObj_9").RealX;
RectangleFramePackObj remarkPpack = template.GetPackObjectOTag<RectangleFramePackObj>("RemarkManage_RectangleFramePackObj_2");
float fontsize = 7f;
int DrawIndex = 0;
double y;
int remarkcount = 12;
double StartRemarkRatio = remarkPpack.RealY;
double EndRemarkRatio = remarkPpack.RealEndY;
try
{
myOpeRecord.ClearDrugsDose(ZedControl);
double allDrugDose = 0; double allOutDose = 0;
myOpeRecord.FactOutputLiquidsList.ForEach(item =>
{
if (item.DosageUnit.Trim() == "mL" || item.DosageUnit.Trim() == "ml" || item.DosageUnit.Trim() == "ML")
{
Double val = Convert.ToDouble(item.Dosage);
allOutDose += val;
}
});
y = StartRemarkRatio + getYPositionByListIndex(DrawIndex, StartRemarkRatio, EndRemarkRatio, remarkcount);
ZUtil.DrawText("总出量:" + allOutDose + " ml", x, y, ZedControl, "allOutDose", Color.Black, fontsize - 0.2f, true);
myOpeRecord.FactOutputLiquidsList.ForEach(item =>
{
if (item.DosageUnit.Trim() == "mL" || item.DosageUnit.Trim() == "ml" || item.DosageUnit.Trim() == "ML")
{
DrawIndex++;
Double val = Convert.ToDouble(item.Dosage);
y = StartRemarkRatio + getYPositionByListIndex(DrawIndex, StartRemarkRatio, EndRemarkRatio, remarkcount);
ZUtil.DrawTextRemark(item.OutputLiquidsName + "" + val + " " + item.DosageUnit, x + 0.01f, y, ZedControl, fontsize, "Out" + DrawIndex);
}
});
myOpeRecord.FactDrugList.ForEach(drug =>
{
//if (drug.DrugEffectId != null && drug.DrugEffectId != 252)
//{
if (drug.Dosage > 0)//&& (drug.DrugAccess != null && drug.DrugAccess > 0)
{
double drugDose = 0;
if (drug.DosageUnit.Trim().ToLower() == "ml") drugDose = Convert.ToDouble(drug.Dosage);
if (drug.DrugChannel == "ivgtt" || drug.DrugChannel == "iv")
{
if (drugDose >= 50)
{
allDrugDose += drugDose;
}
}
}
//}
});
DrawIndex++;
y = StartRemarkRatio + getYPositionByListIndex(DrawIndex, StartRemarkRatio, EndRemarkRatio, remarkcount);
ZUtil.DrawText("总入量:" + allDrugDose + " ml", x, y, ZedControl, "allDrugDose", Color.Black, fontsize - 0.2f, true);
}
catch (Exception ex)
{
PublicMethod.WriteLog(ex);
}
}
#endregion
#region

View File

@ -1215,6 +1215,18 @@ namespace DrawGraph
delAddObj("allSapDosedate");
}
public void ClearDrugsDose(ZedGraphControl zgc)
{
if (zgcAnas == null || zgcAnas != zgc) zgcAnas = zgc;
delAddObj("allDrugDose");
delAddObj("allOutDose");
delAddObj("allqtDrugDose");
for (int i = 1; i <= 19; i++)
{
delAddObj("Out" + i);
}
}
public DataTable AddOtherPhysioParamList()
{
string strSql = "SELECT pc.Id, pc.Name, pc.Color, pc.imgPath, pc.HighLimit, pc.LowLimit,pc.IsValid" +

Some files were not shown because too many files have changed in this diff Show More