DataSet2.cs
上传用户:ksd66jhda
上传日期:2013-04-03
资源大小:234k
文件大小:30k
- //------------------------------------------------------------------------------
- // <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 DataSet2 : DataSet {
-
- private 进货单DataTable table进货单;
-
- public DataSet2() {
- this.InitClass();
- System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
- this.Tables.CollectionChanged += schemaChangedHandler;
- this.Relations.CollectionChanged += schemaChangedHandler;
- }
-
- protected DataSet2(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() {
- DataSet2 cln = ((DataSet2)(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 = "DataSet2";
- this.Prefix = "";
- this.Namespace = "http://www.tempuri.org/DataSet2.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税额;
-
- 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税额;
- }
- }
-
- 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 制单人, System.Decimal 进货数量, System.Decimal 进价, System.Decimal 税价合计, System.Decimal 税率, System.Decimal 不含税价, System.Decimal 税额, string 名称, string 品名, string 仓库, string 单位) {
- 进货单Row row进货单Row = ((进货单Row)(this.NewRow()));
- row进货单Row.ItemArray = new object[] {
- 供货商号,
- 货号,
- 进货日期,
- 业务员,
- 制单人,
- 进货数量,
- 进价,
- 税价合计,
- 税率,
- 不含税价,
- 税额,
- 名称,
- 品名,
- 仓库,
- 单位};
- this.Rows.Add(row进货单Row);
- return row进货单Row;
- }
-
- 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["税额"];
- 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(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(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.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供货商号.AllowDBNull = false;
- this.column货号.AllowDBNull = false;
- this.column进货数量.AllowDBNull = false;
- 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 System.Decimal 进货数量 {
- get {
- return ((System.Decimal)(this[this.table进货单.进货数量Column]));
- }
- 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 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 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 {
- return ((string)(this[this.table进货单.单位Column]));
- }
- 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;
- }
-
- 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;
- }
- }
- }
- }
- }