資源簡介
C#+SQL SERVER耗材管控系統,該系統主板管控耗材入庫、出庫、退領、檔案備份、查詢等功能!!
代碼片段和文件信息
using?System;
using?System.Collections.Generic;
using?System.ComponentModel;
using?System.Data;
using?System.Drawing;
using?System.Linq;
using?System.Text;
using?System.Threading.Tasks;
using?System.Windows.Forms;
using?System.IO;
using?System.Drawing.Imaging;
namespace?Consumable_Control_System_V1._00
{
????public?partial?class?Add_NEW_Item?:?Form
????{
????????public?Add_NEW_Item()
????????{
????????????InitializeComponent();
????????}
????????private?void?Form1_FormClosing(object?sender?FormClosingEventArgs?e)
????????{
????????????System.Environment.Exit(1);
????????}
????????public?String?User_Name?=?String.Empty;
????????public?int?User_Grade?=?0;
????????private?void?Add_NEW_Item_Load(object?sender?EventArgs?e)//區域
????????{
????????????String?Sql_Str?=?“SELECT?*?FROM?Equipment_Use_Area“;
????????????OperationDatabase?GetStorageArea?=?new?OperationDatabase(@“SERVER2\SERVER2“?“E_Material_Control“?“sa“?“adminsystem“?Sql_Str);
????????????if?(GetStorageArea.Get_Storage_Area(comboBox1?“Region_For_Use“))
????????????{
????????????????comboBox1.Focus();
????????????????comboBox1.Enabled?=?true;
????????????}
????????????Option_Windows?ss?=?(Option_Windows)this.Owner;
????????????User_Name?=?ss.User_Name;
????????????User_Grade?=?ss.User_Grade;
????????????textBox6.Text?=?User_Name;
????????}
????????private?void?comboBox1_SelectedIndexChanged(object?sender?EventArgs?e)//品版
????????{
????????????if?(comboBox1.Text?!=?null?&&?comboBox1.Text?!=?String.Empty)
????????????{
????????????????comboBox2.Items.Clear();
????????????????String?Sql_Str?=?“SELECT?*?FROM?Trademark_Table“;
????????????????OperationDatabase?GetTrademark?=?new?OperationDatabase(@“SERVER2\SERVER2“?“E_Material_Control“?“sa“?“adminsystem“?Sql_Str);
????????????????if?(GetTrademark.Get_Storage_Area(comboBox2?“Trademark_Name“))
????????????????{?
????????????????????comboBox1.Enabled?=?false;
????????????????????comboBox2.Enabled?=?true;
????????????????????comboBox2.Focus();
????????????????}
????????????????else
????????????????{
????????????????????comboBox1.Focus();
????????????????????comboBox1.SelectAll();
????????????????}
????????????}
????????????else
????????????{
????????????????comboBox1.Focus();
????????????????comboBox1.SelectAll();
????????????}
????????}
????????private?void?comboBox2_SelectedIndexChanged(object?sender?EventArgs?e)//物品名稱
????????{
????????????if?(comboBox2.Text?!=?null?&&?comboBox2.Text?!=?String.Empty)
????????????{
????????????????comboBox2.Enabled?=?false;
????????????????textBox1.Enabled?=?true;
????????????????textBox1.Focus();
????????????}
????????????else
????????????{
????????????????comboBox2.Focus();
????????????????comboBox2.SelectAll();
????????????}
????????}
????????private?void?textBox1_KeyPress(object?sender?KeyPressEventArgs?e)//物品名稱
????????{
????????????if?(e.KeyChar?==?(Char)Keys.Enter)
????????????{
????????????????if?(text
- 上一篇:Linux 下服務器與客戶端之間的文件傳輸
- 下一篇:在線招聘求職系統
評論
共有 條評論