DataSet1.cs
资源名称:VCSDB.rar [点击查看]
上传用户:hjieqiu
上传日期:2013-05-11
资源大小:16494k
文件大小:26k
源码类别:
企业管理
开发平台:
C#
- //------------------------------------------------------------------------------
- // <autogenerated>
- // This code was generated by a tool.
- // Runtime Version: 1.1.4322.573
- //
- // Changes to this file may cause incorrect behavior and will be lost if
- // the code is regenerated.
- // </autogenerated>
- //------------------------------------------------------------------------------
- namespace 进销存管理系统 {
- using System;
- using System.Data;
- using System.Xml;
- using System.Runtime.Serialization;
- [Serializable()]
- [System.ComponentModel.DesignerCategoryAttribute("code")]
- [System.Diagnostics.DebuggerStepThrough()]
- [System.ComponentModel.ToolboxItem(true)]
- public class DataSet1 : DataSet {
- private 进货单DataTable table进货单;
- public DataSet1() {
- this.InitClass();
- System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
- this.Tables.CollectionChanged += schemaChangedHandler;
- this.Relations.CollectionChanged += schemaChangedHandler;
- }
- protected DataSet1(SerializationInfo info, StreamingContext context) {
- string strSchema = ((string)(info.GetValue("XmlSchema", typeof(string))));
- if ((strSchema != null)) {
- DataSet ds = new DataSet();
- ds.ReadXmlSchema(new XmlTextReader(new System.IO.StringReader(strSchema)));
- if ((ds.Tables["进货单"] != null)) {
- this.Tables.Add(new 进货单DataTable(ds.Tables["进货单"]));
- }
- this.DataSetName = ds.DataSetName;
- this.Prefix = ds.Prefix;
- this.Namespace = ds.Namespace;
- this.Locale = ds.Locale;
- this.CaseSensitive = ds.CaseSensitive;
- this.EnforceConstraints = ds.EnforceConstraints;
- this.Merge(ds, false, System.Data.MissingSchemaAction.Add);
- this.InitVars();
- }
- else {
- this.InitClass();
- }
- this.GetSerializationData(info, context);
- System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
- this.Tables.CollectionChanged += schemaChangedHandler;
- this.Relations.CollectionChanged += schemaChangedHandler;
- }
- [System.ComponentModel.Browsable(false)]
- [System.ComponentModel.DesignerSerializationVisibilityAttribute(System.ComponentModel.DesignerSerializationVisibility.Content)]
- public 进货单DataTable 进货单 {
- get {
- return this.table进货单;
- }
- }
- public override DataSet Clone() {
- DataSet1 cln = ((DataSet1)(base.Clone()));
- cln.InitVars();
- return cln;
- }
- protected override bool ShouldSerializeTables() {
- return false;
- }
- protected override bool ShouldSerializeRelations() {
- return false;
- }
- protected override void ReadXmlSerializable(XmlReader reader) {
- this.Reset();
- DataSet ds = new DataSet();
- ds.ReadXml(reader);
- if ((ds.Tables["进货单"] != null)) {
- this.Tables.Add(new 进货单DataTable(ds.Tables["进货单"]));
- }
- this.DataSetName = ds.DataSetName;
- this.Prefix = ds.Prefix;
- this.Namespace = ds.Namespace;
- this.Locale = ds.Locale;
- this.CaseSensitive = ds.CaseSensitive;
- this.EnforceConstraints = ds.EnforceConstraints;
- this.Merge(ds, false, System.Data.MissingSchemaAction.Add);
- this.InitVars();
- }
- protected override System.Xml.Schema.XmlSchema GetSchemaSerializable() {
- System.IO.MemoryStream stream = new System.IO.MemoryStream();
- this.WriteXmlSchema(new XmlTextWriter(stream, null));
- stream.Position = 0;
- return System.Xml.Schema.XmlSchema.Read(new XmlTextReader(stream), null);
- }
- internal void InitVars() {
- this.table进货单 = ((进货单DataTable)(this.Tables["进货单"]));
- if ((this.table进货单 != null)) {
- this.table进货单.InitVars();
- }
- }
- private void InitClass() {
- this.DataSetName = "DataSet1";
- this.Prefix = "";
- this.Namespace = "http://www.tempuri.org/DataSet1.xsd";
- this.Locale = new System.Globalization.CultureInfo("zh-CN");
- this.CaseSensitive = false;
- this.EnforceConstraints = true;
- this.table进货单 = new 进货单DataTable();
- this.Tables.Add(this.table进货单);
- }
- private bool ShouldSerialize进货单() {
- return false;
- }
- private void SchemaChanged(object sender, System.ComponentModel.CollectionChangeEventArgs e) {
- if ((e.Action == System.ComponentModel.CollectionChangeAction.Remove)) {
- this.InitVars();
- }
- }
- public delegate void 进货单RowChangeEventHandler(object sender, 进货单RowChangeEvent e);
- [System.Diagnostics.DebuggerStepThrough()]
- public class 进货单DataTable : DataTable, System.Collections.IEnumerable {
- private DataColumn column编号;
- private DataColumn column供货商号;
- private DataColumn column进货日期;
- private DataColumn column业务员;
- private DataColumn column制单人;
- private DataColumn column验收员;
- private DataColumn column保管员;
- private DataColumn column税价合计;
- private DataColumn column不含税价;
- private DataColumn column税额;
- private DataColumn column订单号;
- internal 进货单DataTable() :
- base("进货单") {
- this.InitClass();
- }
- internal 进货单DataTable(DataTable table) :
- base(table.TableName) {
- if ((table.CaseSensitive != table.DataSet.CaseSensitive)) {
- this.CaseSensitive = table.CaseSensitive;
- }
- if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) {
- this.Locale = table.Locale;
- }
- if ((table.Namespace != table.DataSet.Namespace)) {
- this.Namespace = table.Namespace;
- }
- this.Prefix = table.Prefix;
- this.MinimumCapacity = table.MinimumCapacity;
- this.DisplayExpression = table.DisplayExpression;
- }
- [System.ComponentModel.Browsable(false)]
- public int Count {
- get {
- return this.Rows.Count;
- }
- }
- internal DataColumn 编号Column {
- get {
- return this.column编号;
- }
- }
- internal DataColumn 供货商号Column {
- get {
- return this.column供货商号;
- }
- }
- internal DataColumn 进货日期Column {
- get {
- return this.column进货日期;
- }
- }
- internal DataColumn 业务员Column {
- get {
- return this.column业务员;
- }
- }
- internal DataColumn 制单人Column {
- get {
- return this.column制单人;
- }
- }
- internal DataColumn 验收员Column {
- get {
- return this.column验收员;
- }
- }
- internal DataColumn 保管员Column {
- get {
- return this.column保管员;
- }
- }
- internal DataColumn 税价合计Column {
- get {
- return this.column税价合计;
- }
- }
- internal DataColumn 不含税价Column {
- get {
- return this.column不含税价;
- }
- }
- internal DataColumn 税额Column {
- get {
- return this.column税额;
- }
- }
- internal DataColumn 订单号Column {
- get {
- return this.column订单号;
- }
- }
- public 进货单Row this[int index] {
- get {
- return ((进货单Row)(this.Rows[index]));
- }
- }
- public event 进货单RowChangeEventHandler 进货单RowChanged;
- public event 进货单RowChangeEventHandler 进货单RowChanging;
- public event 进货单RowChangeEventHandler 进货单RowDeleted;
- public event 进货单RowChangeEventHandler 进货单RowDeleting;
- public void Add进货单Row(进货单Row row) {
- this.Rows.Add(row);
- }
- public 进货单Row Add进货单Row(string 编号, string 供货商号, System.DateTime 进货日期, string 业务员, string 制单人, string 验收员, string 保管员, System.Decimal 税价合计, System.Decimal 不含税价, System.Decimal 税额, string 订单号) {
- 进货单Row row进货单Row = ((进货单Row)(this.NewRow()));
- row进货单Row.ItemArray = new object[] {
- 编号,
- 供货商号,
- 进货日期,
- 业务员,
- 制单人,
- 验收员,
- 保管员,
- 税价合计,
- 不含税价,
- 税额,
- 订单号};
- this.Rows.Add(row进货单Row);
- return row进货单Row;
- }
- public 进货单Row FindBy编号(string 编号) {
- return ((进货单Row)(this.Rows.Find(new object[] {
- 编号})));
- }
- public System.Collections.IEnumerator GetEnumerator() {
- return this.Rows.GetEnumerator();
- }
- public override DataTable Clone() {
- 进货单DataTable cln = ((进货单DataTable)(base.Clone()));
- cln.InitVars();
- return cln;
- }
- protected override DataTable CreateInstance() {
- return new 进货单DataTable();
- }
- internal void InitVars() {
- this.column编号 = this.Columns["编号"];
- this.column供货商号 = this.Columns["供货商号"];
- this.column进货日期 = this.Columns["进货日期"];
- this.column业务员 = this.Columns["业务员"];
- this.column制单人 = this.Columns["制单人"];
- this.column验收员 = this.Columns["验收员"];
- this.column保管员 = this.Columns["保管员"];
- this.column税价合计 = this.Columns["税价合计"];
- this.column不含税价 = this.Columns["不含税价"];
- this.column税额 = this.Columns["税额"];
- this.column订单号 = this.Columns["订单号"];
- }
- private void InitClass() {
- this.column编号 = new DataColumn("编号", typeof(string), null, System.Data.MappingType.Element);
- this.Columns.Add(this.column编号);
- this.column供货商号 = new DataColumn("供货商号", typeof(string), null, System.Data.MappingType.Element);
- this.Columns.Add(this.column供货商号);
- this.column进货日期 = new DataColumn("进货日期", typeof(System.DateTime), null, System.Data.MappingType.Element);
- this.Columns.Add(this.column进货日期);
- this.column业务员 = new DataColumn("业务员", typeof(string), null, System.Data.MappingType.Element);
- this.Columns.Add(this.column业务员);
- this.column制单人 = new DataColumn("制单人", typeof(string), null, System.Data.MappingType.Element);
- this.Columns.Add(this.column制单人);
- this.column验收员 = new DataColumn("验收员", typeof(string), null, System.Data.MappingType.Element);
- this.Columns.Add(this.column验收员);
- this.column保管员 = new DataColumn("保管员", typeof(string), null, System.Data.MappingType.Element);
- this.Columns.Add(this.column保管员);
- this.column税价合计 = new DataColumn("税价合计", typeof(System.Decimal), null, System.Data.MappingType.Element);
- this.Columns.Add(this.column税价合计);
- this.column不含税价 = new DataColumn("不含税价", typeof(System.Decimal), null, System.Data.MappingType.Element);
- this.Columns.Add(this.column不含税价);
- this.column税额 = new DataColumn("税额", typeof(System.Decimal), null, System.Data.MappingType.Element);
- this.Columns.Add(this.column税额);
- this.column订单号 = new DataColumn("订单号", typeof(string), null, System.Data.MappingType.Element);
- this.Columns.Add(this.column订单号);
- this.Constraints.Add(new UniqueConstraint("Constraint1", new DataColumn[] {
- this.column编号}, true));
- this.column编号.AllowDBNull = false;
- this.column编号.Unique = true;
- this.column供货商号.AllowDBNull = false;
- }
- public 进货单Row New进货单Row() {
- return ((进货单Row)(this.NewRow()));
- }
- protected override DataRow NewRowFromBuilder(DataRowBuilder builder) {
- return new 进货单Row(builder);
- }
- protected override System.Type GetRowType() {
- return typeof(进货单Row);
- }
- protected override void OnRowChanged(DataRowChangeEventArgs e) {
- base.OnRowChanged(e);
- if ((this.进货单RowChanged != null)) {
- this.进货单RowChanged(this, new 进货单RowChangeEvent(((进货单Row)(e.Row)), e.Action));
- }
- }
- protected override void OnRowChanging(DataRowChangeEventArgs e) {
- base.OnRowChanging(e);
- if ((this.进货单RowChanging != null)) {
- this.进货单RowChanging(this, new 进货单RowChangeEvent(((进货单Row)(e.Row)), e.Action));
- }
- }
- protected override void OnRowDeleted(DataRowChangeEventArgs e) {
- base.OnRowDeleted(e);
- if ((this.进货单RowDeleted != null)) {
- this.进货单RowDeleted(this, new 进货单RowChangeEvent(((进货单Row)(e.Row)), e.Action));
- }
- }
- protected override void OnRowDeleting(DataRowChangeEventArgs e) {
- base.OnRowDeleting(e);
- if ((this.进货单RowDeleting != null)) {
- this.进货单RowDeleting(this, new 进货单RowChangeEvent(((进货单Row)(e.Row)), e.Action));
- }
- }
- public void Remove进货单Row(进货单Row row) {
- this.Rows.Remove(row);
- }
- }
- [System.Diagnostics.DebuggerStepThrough()]
- public class 进货单Row : DataRow {
- private 进货单DataTable table进货单;
- internal 进货单Row(DataRowBuilder rb) :
- base(rb) {
- this.table进货单 = ((进货单DataTable)(this.Table));
- }
- public string 编号 {
- get {
- return ((string)(this[this.table进货单.编号Column]));
- }
- set {
- this[this.table进货单.编号Column] = value;
- }
- }
- public string 供货商号 {
- get {
- return ((string)(this[this.table进货单.供货商号Column]));
- }
- set {
- this[this.table进货单.供货商号Column] = value;
- }
- }
- public System.DateTime 进货日期 {
- get {
- try {
- return ((System.DateTime)(this[this.table进货单.进货日期Column]));
- }
- catch (InvalidCastException e) {
- throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
- }
- }
- set {
- this[this.table进货单.进货日期Column] = value;
- }
- }
- public string 业务员 {
- get {
- try {
- return ((string)(this[this.table进货单.业务员Column]));
- }
- catch (InvalidCastException e) {
- throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
- }
- }
- set {
- this[this.table进货单.业务员Column] = value;
- }
- }
- public string 制单人 {
- get {
- try {
- return ((string)(this[this.table进货单.制单人Column]));
- }
- catch (InvalidCastException e) {
- throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
- }
- }
- set {
- this[this.table进货单.制单人Column] = value;
- }
- }
- public string 验收员 {
- get {
- try {
- return ((string)(this[this.table进货单.验收员Column]));
- }
- catch (InvalidCastException e) {
- throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
- }
- }
- set {
- this[this.table进货单.验收员Column] = value;
- }
- }
- public string 保管员 {
- get {
- try {
- return ((string)(this[this.table进货单.保管员Column]));
- }
- catch (InvalidCastException e) {
- throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
- }
- }
- set {
- this[this.table进货单.保管员Column] = value;
- }
- }
- public System.Decimal 税价合计 {
- get {
- try {
- return ((System.Decimal)(this[this.table进货单.税价合计Column]));
- }
- catch (InvalidCastException e) {
- throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
- }
- }
- set {
- this[this.table进货单.税价合计Column] = value;
- }
- }
- public System.Decimal 不含税价 {
- get {
- try {
- return ((System.Decimal)(this[this.table进货单.不含税价Column]));
- }
- catch (InvalidCastException e) {
- throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
- }
- }
- set {
- this[this.table进货单.不含税价Column] = value;
- }
- }
- public System.Decimal 税额 {
- get {
- try {
- return ((System.Decimal)(this[this.table进货单.税额Column]));
- }
- catch (InvalidCastException e) {
- throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
- }
- }
- set {
- this[this.table进货单.税额Column] = value;
- }
- }
- public string 订单号 {
- get {
- try {
- return ((string)(this[this.table进货单.订单号Column]));
- }
- catch (InvalidCastException e) {
- throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
- }
- }
- set {
- this[this.table进货单.订单号Column] = value;
- }
- }
- public bool Is进货日期Null() {
- return this.IsNull(this.table进货单.进货日期Column);
- }
- public void Set进货日期Null() {
- this[this.table进货单.进货日期Column] = System.Convert.DBNull;
- }
- public bool Is业务员Null() {
- return this.IsNull(this.table进货单.业务员Column);
- }
- public void Set业务员Null() {
- this[this.table进货单.业务员Column] = System.Convert.DBNull;
- }
- public bool Is制单人Null() {
- return this.IsNull(this.table进货单.制单人Column);
- }
- public void Set制单人Null() {
- this[this.table进货单.制单人Column] = System.Convert.DBNull;
- }
- public bool Is验收员Null() {
- return this.IsNull(this.table进货单.验收员Column);
- }
- public void Set验收员Null() {
- this[this.table进货单.验收员Column] = System.Convert.DBNull;
- }
- public bool Is保管员Null() {
- return this.IsNull(this.table进货单.保管员Column);
- }
- public void Set保管员Null() {
- this[this.table进货单.保管员Column] = System.Convert.DBNull;
- }
- public bool Is税价合计Null() {
- return this.IsNull(this.table进货单.税价合计Column);
- }
- public void Set税价合计Null() {
- this[this.table进货单.税价合计Column] = System.Convert.DBNull;
- }
- public bool Is不含税价Null() {
- return this.IsNull(this.table进货单.不含税价Column);
- }
- public void Set不含税价Null() {
- this[this.table进货单.不含税价Column] = System.Convert.DBNull;
- }
- public bool Is税额Null() {
- return this.IsNull(this.table进货单.税额Column);
- }
- public void Set税额Null() {
- this[this.table进货单.税额Column] = System.Convert.DBNull;
- }
- public bool Is订单号Null() {
- return this.IsNull(this.table进货单.订单号Column);
- }
- public void Set订单号Null() {
- this[this.table进货单.订单号Column] = System.Convert.DBNull;
- }
- }
- [System.Diagnostics.DebuggerStepThrough()]
- public class 进货单RowChangeEvent : EventArgs {
- private 进货单Row eventRow;
- private DataRowAction eventAction;
- public 进货单RowChangeEvent(进货单Row row, DataRowAction action) {
- this.eventRow = row;
- this.eventAction = action;
- }
- public 进货单Row Row {
- get {
- return this.eventRow;
- }
- }
- public DataRowAction Action {
- get {
- return this.eventAction;
- }
- }
- }
- }
- }