From 7fff92cf46fa79a633f437d370693ae79fb8320c Mon Sep 17 00:00:00 2001 From: zhangqi7131 Date: Fri, 26 Jul 2024 16:38:42 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E9=A1=B9=E7=9B=AE=E6=96=87?= =?UTF-8?q?=E4=BB=B6=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- STS.sln | 25 +++ STS/App.config | 6 + STS/Form1.Designer.cs | 295 +++++++++++++++++++++++++++ STS/Form1.cs | 166 +++++++++++++++ STS/Form1.resx | 159 +++++++++++++++ STS/Program.cs | 22 ++ STS/Properties/AssemblyInfo.cs | 36 ++++ STS/Properties/Resources.Designer.cs | 71 +++++++ STS/Properties/Resources.resx | 117 +++++++++++ STS/Properties/Settings.Designer.cs | 30 +++ STS/Properties/Settings.settings | 7 + STS/STS.csproj | 83 ++++++++ 12 files changed, 1017 insertions(+) create mode 100644 STS.sln create mode 100644 STS/App.config create mode 100644 STS/Form1.Designer.cs create mode 100644 STS/Form1.cs create mode 100644 STS/Form1.resx create mode 100644 STS/Program.cs create mode 100644 STS/Properties/AssemblyInfo.cs create mode 100644 STS/Properties/Resources.Designer.cs create mode 100644 STS/Properties/Resources.resx create mode 100644 STS/Properties/Settings.Designer.cs create mode 100644 STS/Properties/Settings.settings create mode 100644 STS/STS.csproj diff --git a/STS.sln b/STS.sln new file mode 100644 index 0000000..1e9962e --- /dev/null +++ b/STS.sln @@ -0,0 +1,25 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 17 +VisualStudioVersion = 17.10.35027.167 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "STS", "STS\STS.csproj", "{C9DA7067-0865-4CC7-9EED-2C8D3C104C3D}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {C9DA7067-0865-4CC7-9EED-2C8D3C104C3D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {C9DA7067-0865-4CC7-9EED-2C8D3C104C3D}.Debug|Any CPU.Build.0 = Debug|Any CPU + {C9DA7067-0865-4CC7-9EED-2C8D3C104C3D}.Release|Any CPU.ActiveCfg = Release|Any CPU + {C9DA7067-0865-4CC7-9EED-2C8D3C104C3D}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {03824371-5823-4001-9DFD-32EAB63B2A16} + EndGlobalSection +EndGlobal diff --git a/STS/App.config b/STS/App.config new file mode 100644 index 0000000..56efbc7 --- /dev/null +++ b/STS/App.config @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/STS/Form1.Designer.cs b/STS/Form1.Designer.cs new file mode 100644 index 0000000..3ae4b1a --- /dev/null +++ b/STS/Form1.Designer.cs @@ -0,0 +1,295 @@ +namespace STS +{ + partial class Form1 + { + /// + /// 必需的设计器变量。 + /// + private System.ComponentModel.IContainer components = null; + + /// + /// 清理所有正在使用的资源。 + /// + /// 如果应释放托管资源,为 true;否则为 false。 + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows 窗体设计器生成的代码 + + /// + /// 设计器支持所需的方法 - 不要修改 + /// 使用代码编辑器修改此方法的内容。 + /// + private void InitializeComponent() + { + this.components = new System.ComponentModel.Container(); + this.dataGridView1 = new System.Windows.Forms.DataGridView(); + this.contextMenuStrip1 = new System.Windows.Forms.ContextMenuStrip(this.components); + this.toolStripMenuItem1 = new System.Windows.Forms.ToolStripMenuItem(); + this.toolStripMenuItem2 = new System.Windows.Forms.ToolStripMenuItem(); + this.querybtn1 = new System.Windows.Forms.Button(); + this.label1 = new System.Windows.Forms.Label(); + this.textBox1 = new System.Windows.Forms.TextBox(); + this.comboBox1 = new System.Windows.Forms.ComboBox(); + this.Barcode_DGV = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.Column2 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.Column3 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.Column4 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.Column5 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.Column6 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.Column7 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.Column8 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.Column9 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.Column10 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.Column11 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.Column12 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + ((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit(); + this.contextMenuStrip1.SuspendLayout(); + this.SuspendLayout(); + // + // dataGridView1 + // + this.dataGridView1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; + this.dataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { + this.Barcode_DGV, + this.Column2, + this.Column3, + this.Column4, + this.Column5, + this.Column6, + this.Column7, + this.Column8, + this.Column9, + this.Column10, + this.Column11, + this.Column12}); + this.dataGridView1.ContextMenuStrip = this.contextMenuStrip1; + this.dataGridView1.Location = new System.Drawing.Point(35, 79); + this.dataGridView1.Name = "dataGridView1"; + this.dataGridView1.ReadOnly = true; + this.dataGridView1.RowHeadersWidth = 51; + this.dataGridView1.RowTemplate.Height = 27; + this.dataGridView1.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect; + this.dataGridView1.Size = new System.Drawing.Size(1280, 600); + this.dataGridView1.TabIndex = 0; + this.dataGridView1.CellMouseDown += new System.Windows.Forms.DataGridViewCellMouseEventHandler(this.dataGridView1_CellMouseDown); + // + // contextMenuStrip1 + // + this.contextMenuStrip1.ImageScalingSize = new System.Drawing.Size(20, 20); + this.contextMenuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { + this.toolStripMenuItem1, + this.toolStripMenuItem2}); + this.contextMenuStrip1.Name = "contextMenuStrip1"; + this.contextMenuStrip1.Size = new System.Drawing.Size(169, 52); + // + // toolStripMenuItem1 + // + this.toolStripMenuItem1.Name = "toolStripMenuItem1"; + this.toolStripMenuItem1.Size = new System.Drawing.Size(168, 24); + this.toolStripMenuItem1.Text = "【任务完成】"; + this.toolStripMenuItem1.Click += new System.EventHandler(this.toolStripMenuItem1_Click); + // + // toolStripMenuItem2 + // + this.toolStripMenuItem2.Name = "toolStripMenuItem2"; + this.toolStripMenuItem2.Size = new System.Drawing.Size(168, 24); + this.toolStripMenuItem2.Text = "【任务删除】"; + this.toolStripMenuItem2.Click += new System.EventHandler(this.toolStripMenuItem2_Click); + // + // querybtn1 + // + this.querybtn1.Location = new System.Drawing.Point(876, 35); + this.querybtn1.Name = "querybtn1"; + this.querybtn1.Size = new System.Drawing.Size(101, 25); + this.querybtn1.TabIndex = 1; + this.querybtn1.Text = "开始查询"; + this.querybtn1.UseVisualStyleBackColor = true; + this.querybtn1.Click += new System.EventHandler(this.querybtn1_Click); + // + // label1 + // + this.label1.AutoSize = true; + this.label1.Location = new System.Drawing.Point(451, 39); + this.label1.Name = "label1"; + this.label1.Size = new System.Drawing.Size(67, 15); + this.label1.TabIndex = 2; + this.label1.Text = "任务查询"; + // + // textBox1 + // + this.textBox1.Location = new System.Drawing.Point(742, 35); + this.textBox1.Name = "textBox1"; + this.textBox1.Size = new System.Drawing.Size(128, 25); + this.textBox1.TabIndex = 3; + // + // comboBox1 + // + this.comboBox1.FormattingEnabled = true; + this.comboBox1.Items.AddRange(new object[] { + "条码", + "调度任务索引"}); + this.comboBox1.Location = new System.Drawing.Point(529, 36); + this.comboBox1.Name = "comboBox1"; + this.comboBox1.Size = new System.Drawing.Size(192, 23); + this.comboBox1.TabIndex = 4; + // + // Barcode_DGV + // + this.Barcode_DGV.DataPropertyName = "Barcode"; + this.Barcode_DGV.HeaderText = "条码"; + this.Barcode_DGV.MinimumWidth = 6; + this.Barcode_DGV.Name = "Barcode_DGV"; + this.Barcode_DGV.ReadOnly = true; + this.Barcode_DGV.Width = 70; + // + // Column2 + // + this.Column2.DataPropertyName = "ScheduledTaskIndex"; + this.Column2.HeaderText = "调度任务索引"; + this.Column2.MinimumWidth = 6; + this.Column2.Name = "Column2"; + this.Column2.ReadOnly = true; + this.Column2.Width = 70; + // + // Column3 + // + this.Column3.DataPropertyName = "RelatedTaskIndex"; + this.Column3.HeaderText = "关联任务索引"; + this.Column3.MinimumWidth = 6; + this.Column3.Name = "Column3"; + this.Column3.ReadOnly = true; + this.Column3.Width = 70; + // + // Column4 + // + this.Column4.DataPropertyName = "TaskType"; + this.Column4.HeaderText = "任务类型"; + this.Column4.MinimumWidth = 6; + this.Column4.Name = "Column4"; + this.Column4.ReadOnly = true; + this.Column4.Width = 80; + // + // Column5 + // + this.Column5.DataPropertyName = "JobType"; + this.Column5.HeaderText = "作业类型"; + this.Column5.MinimumWidth = 6; + this.Column5.Name = "Column5"; + this.Column5.ReadOnly = true; + this.Column5.Width = 60; + // + // Column6 + // + this.Column6.DataPropertyName = "StartPoint"; + this.Column6.HeaderText = "起点"; + this.Column6.MinimumWidth = 6; + this.Column6.Name = "Column6"; + this.Column6.ReadOnly = true; + this.Column6.Width = 60; + // + // Column7 + // + this.Column7.DataPropertyName = "StartLocation"; + this.Column7.HeaderText = "起点货位"; + this.Column7.MinimumWidth = 6; + this.Column7.Name = "Column7"; + this.Column7.ReadOnly = true; + this.Column7.Width = 60; + // + // Column8 + // + this.Column8.DataPropertyName = "EndPoint"; + this.Column8.HeaderText = "终点"; + this.Column8.MinimumWidth = 6; + this.Column8.Name = "Column8"; + this.Column8.ReadOnly = true; + this.Column8.Width = 60; + // + // Column9 + // + this.Column9.DataPropertyName = "EndLocation"; + this.Column9.HeaderText = "终点货位"; + this.Column9.MinimumWidth = 6; + this.Column9.Name = "Column9"; + this.Column9.ReadOnly = true; + this.Column9.Width = 60; + // + // Column10 + // + this.Column10.DataPropertyName = "TaskStatus"; + this.Column10.HeaderText = "任务状态"; + this.Column10.MinimumWidth = 6; + this.Column10.Name = "Column10"; + this.Column10.ReadOnly = true; + this.Column10.Width = 60; + // + // Column11 + // + this.Column11.DataPropertyName = "StartTime"; + this.Column11.HeaderText = "开始时间"; + this.Column11.MinimumWidth = 6; + this.Column11.Name = "Column11"; + this.Column11.ReadOnly = true; + this.Column11.Width = 125; + // + // Column12 + // + this.Column12.DataPropertyName = "ErrorInformation"; + this.Column12.HeaderText = "故障信息"; + this.Column12.MinimumWidth = 6; + this.Column12.Name = "Column12"; + this.Column12.ReadOnly = true; + this.Column12.Width = 60; + // + // Form1 + // + this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.ClientSize = new System.Drawing.Size(1348, 721); + this.Controls.Add(this.comboBox1); + this.Controls.Add(this.textBox1); + this.Controls.Add(this.label1); + this.Controls.Add(this.querybtn1); + this.Controls.Add(this.dataGridView1); + this.Name = "Form1"; + this.Text = "调度任务管理"; + this.Load += new System.EventHandler(this.Form1_Load); + ((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).EndInit(); + this.contextMenuStrip1.ResumeLayout(false); + this.ResumeLayout(false); + this.PerformLayout(); + + } + + #endregion + + private System.Windows.Forms.DataGridView dataGridView1; + private System.Windows.Forms.Button querybtn1; + private System.Windows.Forms.Label label1; + private System.Windows.Forms.TextBox textBox1; + private System.Windows.Forms.ComboBox comboBox1; + private System.Windows.Forms.ContextMenuStrip contextMenuStrip1; + private System.Windows.Forms.ToolStripMenuItem toolStripMenuItem1; + private System.Windows.Forms.ToolStripMenuItem toolStripMenuItem2; + private System.Windows.Forms.DataGridViewTextBoxColumn Barcode_DGV; + private System.Windows.Forms.DataGridViewTextBoxColumn Column2; + private System.Windows.Forms.DataGridViewTextBoxColumn Column3; + private System.Windows.Forms.DataGridViewTextBoxColumn Column4; + private System.Windows.Forms.DataGridViewTextBoxColumn Column5; + private System.Windows.Forms.DataGridViewTextBoxColumn Column6; + private System.Windows.Forms.DataGridViewTextBoxColumn Column7; + private System.Windows.Forms.DataGridViewTextBoxColumn Column8; + private System.Windows.Forms.DataGridViewTextBoxColumn Column9; + private System.Windows.Forms.DataGridViewTextBoxColumn Column10; + private System.Windows.Forms.DataGridViewTextBoxColumn Column11; + private System.Windows.Forms.DataGridViewTextBoxColumn Column12; + } +} + diff --git a/STS/Form1.cs b/STS/Form1.cs new file mode 100644 index 0000000..92548f2 --- /dev/null +++ b/STS/Form1.cs @@ -0,0 +1,166 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Data.SqlClient; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace STS +{ + public partial class Form1 : Form + { + public Form1() + { + InitializeComponent(); + } + + private void Form1_Load(object sender, EventArgs e) + { + showAllInformation(); + //开始时不选中任何行 + dataGridView1.ClearSelection(); + } + + //展示数据库表中所有信息 + private void showAllInformation() + { + SqlConnection conn = new SqlConnection(); + conn.ConnectionString = "Server=localhost;Database=TaskManagementDB;Trusted_Connection=True;"; + conn.Open(); + SqlCommand cmd = new SqlCommand(); + cmd.Connection = conn; + cmd.CommandText = "select * from STM"; + + SqlDataAdapter adapter = new SqlDataAdapter(); + adapter.SelectCommand = cmd; + + DataSet ds = new DataSet(); + adapter.Fill(ds, "STM"); + + DataTable dt = ds.Tables["STM"]; + dataGridView1.DataSource = dt; + conn.Close(); + } + + //单击“开始查询”按钮触发事件 + private void querybtn1_Click(object sender, EventArgs e) + { + string key = comboBox1.Text; + string value = textBox1.Text; + if (key == "条码") + { + key = "Barcode"; + } + else if (key == "调度任务索引") + { + key = "ScheduledTaskIndex"; + } + + SqlConnection conn = new SqlConnection(); + conn.ConnectionString = "Server=localhost;Database=TaskManagementDB;Trusted_Connection=True;"; + conn.Open(); + SqlCommand cmd = new SqlCommand(); + cmd.Connection = conn; + + //如果有一项为空,则列出所有数据并提示 + if (key == "" || value == "") + { + cmd.CommandText = "select * from STM"; + //MessageBox.Show("缺少查询条件,展示全部数据!"); + } + else + { + cmd.CommandText = $"select * from STM where {key}='{value}'"; + } + SqlDataAdapter adapter = new SqlDataAdapter(); + adapter.SelectCommand = cmd; + + DataSet ds = new DataSet(); + adapter.Fill(ds, "STM"); + + DataTable dt = ds.Tables["STM"]; + dataGridView1.DataSource = dt; + conn.Close(); + } + + //鼠标右键单击某行,触发事件 + private void dataGridView1_CellMouseDown(object sender, DataGridViewCellMouseEventArgs e) + { + if (e.Button == MouseButtons.Right && e.RowIndex > -1 && e.ColumnIndex > -1) + { + dataGridView1.CurrentRow.Selected = false; + dataGridView1.Rows[e.RowIndex].Selected = true; + dataGridView1.CurrentCell = dataGridView1.Rows[e.RowIndex].Cells[e.ColumnIndex]; + } + } + + //单击“任务删除”触发事件 + private void toolStripMenuItem2_Click(object sender, EventArgs e) + { + //确定该行条码值 + int crindex = dataGridView1.CurrentRow.Index; + string barcode = dataGridView1.Rows[crindex].Cells["Barcode_DGV"].Value.ToString(); + //确认删除提示 + string message = $"确定要删除该条信息?\n条码:{barcode}"; + string title = "警告"; + MessageBoxButtons buttons = MessageBoxButtons.YesNo; + DialogResult result = MessageBox.Show(message, title, buttons, MessageBoxIcon.Warning); + //选择“否”则结束方法 + if (result == DialogResult.No) + { + return; + } + //数据库连接 + SqlConnection conn = new SqlConnection(); + conn.ConnectionString = "Server=localhost;Database=TaskManagementDB;Trusted_Connection=True;"; + conn.Open(); + SqlCommand cmd = new SqlCommand(); + cmd.Connection = conn; + cmd.CommandText = $"delete from STM where Barcode='{barcode}'"; + //执行语句并记录受影响的行数 + int deletenum = cmd.ExecuteNonQuery(); + conn.Close(); + if (deletenum > 0) + { + MessageBox.Show("删除成功!"); + //刷新dataGridView + showAllInformation(); + } + else + { + MessageBox.Show("删除失败!"); + } + } + + //单击“任务完成”触发事件 + private void toolStripMenuItem1_Click(object sender, EventArgs e) + { + //确定条码值 + int crindex = dataGridView1.CurrentRow.Index; + string barcode = dataGridView1.Rows[crindex].Cells["Barcode_DGV"].Value.ToString(); + + SqlConnection conn = new SqlConnection(); + conn.ConnectionString = "Server=localhost;Database=TaskManagementDB;Trusted_Connection=True;"; + conn.Open(); + SqlCommand cmd = new SqlCommand(); + cmd.Connection = conn; + cmd.CommandText = $"update STM set TaskStatus='已完成' where Barcode='{barcode}'"; + //执行语句并记录受影响的行数 + int updatenum = cmd.ExecuteNonQuery(); + conn.Close(); + if (updatenum > 0) + { + MessageBox.Show("任务状态更新成功!"); + showAllInformation(); + } + else + { + MessageBox.Show("任务状态更新失败!"); + } + } + } +} diff --git a/STS/Form1.resx b/STS/Form1.resx new file mode 100644 index 0000000..732e28b --- /dev/null +++ b/STS/Form1.resx @@ -0,0 +1,159 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + 17, 17 + + \ No newline at end of file diff --git a/STS/Program.cs b/STS/Program.cs new file mode 100644 index 0000000..370826d --- /dev/null +++ b/STS/Program.cs @@ -0,0 +1,22 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace STS +{ + internal static class Program + { + /// + /// 应用程序的主入口点。 + /// + [STAThread] + static void Main() + { + Application.EnableVisualStyles(); + Application.SetCompatibleTextRenderingDefault(false); + Application.Run(new Form1()); + } + } +} diff --git a/STS/Properties/AssemblyInfo.cs b/STS/Properties/AssemblyInfo.cs new file mode 100644 index 0000000..9a7f474 --- /dev/null +++ b/STS/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +// 有关程序集的一般信息由以下 +// 控制。更改这些特性值可修改 +// 与程序集关联的信息。 +[assembly: AssemblyTitle("STS")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("STS")] +[assembly: AssemblyCopyright("Copyright © 2024")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// 将 ComVisible 设置为 false 会使此程序集中的类型 +//对 COM 组件不可见。如果需要从 COM 访问此程序集中的类型 +//请将此类型的 ComVisible 特性设置为 true。 +[assembly: ComVisible(false)] + +// 如果此项目向 COM 公开,则下列 GUID 用于类型库的 ID +[assembly: Guid("c9da7067-0865-4cc7-9eed-2c8d3c104c3d")] + +// 程序集的版本信息由下列四个值组成: +// +// 主版本 +// 次版本 +// 生成号 +// 修订号 +// +//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值 +//通过使用 "*",如下所示: +// [assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/STS/Properties/Resources.Designer.cs b/STS/Properties/Resources.Designer.cs new file mode 100644 index 0000000..14b09b4 --- /dev/null +++ b/STS/Properties/Resources.Designer.cs @@ -0,0 +1,71 @@ +//------------------------------------------------------------------------------ +// +// 此代码由工具生成。 +// 运行时版本: 4.0.30319.42000 +// +// 对此文件的更改可能导致不正确的行为,如果 +// 重新生成代码,则所做更改将丢失。 +// +//------------------------------------------------------------------------------ + +namespace STS.Properties +{ + + + /// + /// 强类型资源类,用于查找本地化字符串等。 + /// + // 此类是由 StronglyTypedResourceBuilder + // 类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。 + // 若要添加或移除成员,请编辑 .ResX 文件,然后重新运行 ResGen + // (以 /str 作为命令选项),或重新生成 VS 项目。 + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")] + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] + internal class Resources + { + + private static global::System.Resources.ResourceManager resourceMan; + + private static global::System.Globalization.CultureInfo resourceCulture; + + [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] + internal Resources() + { + } + + /// + /// 返回此类使用的缓存 ResourceManager 实例。 + /// + [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] + internal static global::System.Resources.ResourceManager ResourceManager + { + get + { + if ((resourceMan == null)) + { + global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("STS.Properties.Resources", typeof(Resources).Assembly); + resourceMan = temp; + } + return resourceMan; + } + } + + /// + /// 重写当前线程的 CurrentUICulture 属性,对 + /// 使用此强类型资源类的所有资源查找执行重写。 + /// + [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] + internal static global::System.Globalization.CultureInfo Culture + { + get + { + return resourceCulture; + } + set + { + resourceCulture = value; + } + } + } +} diff --git a/STS/Properties/Resources.resx b/STS/Properties/Resources.resx new file mode 100644 index 0000000..af7dbeb --- /dev/null +++ b/STS/Properties/Resources.resx @@ -0,0 +1,117 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/STS/Properties/Settings.Designer.cs b/STS/Properties/Settings.Designer.cs new file mode 100644 index 0000000..779289e --- /dev/null +++ b/STS/Properties/Settings.Designer.cs @@ -0,0 +1,30 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Runtime Version:4.0.30319.42000 +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +namespace STS.Properties +{ + + + [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")] + internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase + { + + private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); + + public static Settings Default + { + get + { + return defaultInstance; + } + } + } +} diff --git a/STS/Properties/Settings.settings b/STS/Properties/Settings.settings new file mode 100644 index 0000000..3964565 --- /dev/null +++ b/STS/Properties/Settings.settings @@ -0,0 +1,7 @@ + + + + + + + diff --git a/STS/STS.csproj b/STS/STS.csproj new file mode 100644 index 0000000..afb28b5 --- /dev/null +++ b/STS/STS.csproj @@ -0,0 +1,83 @@ + + + + + Debug + AnyCPU + {C9DA7067-0865-4CC7-9EED-2C8D3C104C3D} + WinExe + STS + STS + v4.7.2 + 512 + true + true + + + AnyCPU + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + AnyCPU + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + + + + + + + + + + + + + + Form + + + Form1.cs + + + + + Form1.cs + + + ResXFileCodeGenerator + Resources.Designer.cs + Designer + + + True + Resources.resx + + + SettingsSingleFileGenerator + Settings.Designer.cs + + + True + Settings.settings + True + + + + + + + \ No newline at end of file