?? dataset2.cs
字號:
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 卡號, 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["密碼"];
}
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(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;
}
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 {
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 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;
}
}
[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;
}
}
}
}
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -