📄 mystuinfodbdataset10.designer.cs
字号:
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void InitConnection() {
this._connection = new System.Data.SqlClient.SqlConnection();
this._connection.ConnectionString = global::StudentInfoMS.Properties.Settings.Default.mystuInfoDBConnectionString;
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void InitCommandCollection() {
this._commandCollection = new System.Data.SqlClient.SqlCommand[1];
this._commandCollection[0] = new System.Data.SqlClient.SqlCommand();
this._commandCollection[0].Connection = this.Connection;
this._commandCollection[0].CommandText = "SELECT sid, sname, sex, minzu, jiguan, birthday, homeaddress, postcode FROM dbo.s" +
"tudentInfo";
this._commandCollection[0].CommandType = System.Data.CommandType.Text;
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[System.ComponentModel.DataObjectMethodAttribute(System.ComponentModel.DataObjectMethodType.Fill, true)]
public virtual int Fill(mystuInfoDBDataSet.studentInfoDataTable dataTable) {
this.Adapter.SelectCommand = this.CommandCollection[0];
if ((this.ClearBeforeFill == true)) {
dataTable.Clear();
}
int returnValue = this.Adapter.Fill(dataTable);
return returnValue;
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[System.ComponentModel.DataObjectMethodAttribute(System.ComponentModel.DataObjectMethodType.Select, true)]
public virtual mystuInfoDBDataSet.studentInfoDataTable GetData() {
this.Adapter.SelectCommand = this.CommandCollection[0];
mystuInfoDBDataSet.studentInfoDataTable dataTable = new mystuInfoDBDataSet.studentInfoDataTable();
this.Adapter.Fill(dataTable);
return dataTable;
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(mystuInfoDBDataSet.studentInfoDataTable dataTable) {
return this.Adapter.Update(dataTable);
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(mystuInfoDBDataSet dataSet) {
return this.Adapter.Update(dataSet, "studentInfo");
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(System.Data.DataRow dataRow) {
return this.Adapter.Update(new System.Data.DataRow[] {
dataRow});
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(System.Data.DataRow[] dataRows) {
return this.Adapter.Update(dataRows);
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[System.ComponentModel.DataObjectMethodAttribute(System.ComponentModel.DataObjectMethodType.Delete, true)]
public virtual int Delete(string Original_sid, string Original_sname, string Original_sex, string Original_minzu, string Original_jiguan, System.Nullable<System.DateTime> Original_birthday, string Original_homeaddress, string Original_postcode) {
if ((Original_sid == null)) {
throw new System.ArgumentNullException("Original_sid");
}
else {
this.Adapter.DeleteCommand.Parameters[0].Value = ((string)(Original_sid));
}
if ((Original_sname == null)) {
this.Adapter.DeleteCommand.Parameters[1].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[2].Value = System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[1].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[2].Value = ((string)(Original_sname));
}
if ((Original_sex == null)) {
this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[4].Value = System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[4].Value = ((string)(Original_sex));
}
if ((Original_minzu == null)) {
this.Adapter.DeleteCommand.Parameters[5].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[6].Value = System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[5].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[6].Value = ((string)(Original_minzu));
}
if ((Original_jiguan == null)) {
this.Adapter.DeleteCommand.Parameters[7].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[8].Value = System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[7].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[8].Value = ((string)(Original_jiguan));
}
if ((Original_birthday.HasValue == true)) {
this.Adapter.DeleteCommand.Parameters[9].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[10].Value = ((System.DateTime)(Original_birthday.Value));
}
else {
this.Adapter.DeleteCommand.Parameters[9].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[10].Value = System.DBNull.Value;
}
if ((Original_homeaddress == null)) {
this.Adapter.DeleteCommand.Parameters[11].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[12].Value = System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[11].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[12].Value = ((string)(Original_homeaddress));
}
if ((Original_postcode == null)) {
this.Adapter.DeleteCommand.Parameters[13].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[14].Value = System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[13].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[14].Value = ((string)(Original_postcode));
}
System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
if (((this.Adapter.DeleteCommand.Connection.State & System.Data.ConnectionState.Open)
!= System.Data.ConnectionState.Open)) {
this.Adapter.DeleteCommand.Connection.Open();
}
try {
int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
return returnValue;
}
finally {
if ((previousConnectionState == System.Data.ConnectionState.Closed)) {
this.Adapter.DeleteCommand.Connection.Close();
}
}
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[System.ComponentModel.DataObjectMethodAttribute(System.ComponentModel.DataObjectMethodType.Insert, true)]
public virtual int Insert(string sid, string sname, string sex, string minzu, string jiguan, System.Nullable<System.DateTime> birthday, string homeaddress, string postcode) {
if ((sid == null)) {
throw new System.ArgumentNullException("sid");
}
else {
this.Adapter.InsertCommand.Parameters[0].Value = ((string)(sid));
}
if ((sname == null)) {
this.Adapter.InsertCommand.Parameters[1].Value = System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[1].Value = ((string)(sname));
}
if ((sex == null)) {
this.Adapter.InsertCommand.Parameters[2].Value = System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[2].Value = ((string)(sex));
}
if ((minzu == null)) {
this.Adapter.InsertCommand.Parameters[3].Value = System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[3].Value = ((string)(minzu));
}
if ((jiguan == null)) {
this.Adapter.InsertCommand.Parameters[4].Value = System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[4].Value = ((string)(jiguan));
}
if ((birthday.HasValue == true)) {
this.Adapter.InsertCommand.Parameters[5].Value = ((System.DateTime)(birthday.Value));
}
else {
this.Adapter.InsertCommand.Parameters[5].Value = System.DBNull.Value;
}
if ((homeaddress == null)) {
this.Adapter.InsertCommand.Parameters[6].Value = System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[6].Value = ((string)(homeaddress));
}
if ((postcode == null)) {
this.Adapter.InsertCommand.Parameters[7].Value = System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[7].Value = ((string)(postcode));
}
System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
if (((this.Adapter.InsertCommand.Connection.State & System.Data.ConnectionState.Open)
!= System.Data.ConnectionState.Open)) {
this.Adapter.InsertCommand.Connection.Open();
}
try {
int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
return returnValue;
}
finally {
if ((previousConnectionState == System.Data.ConnectionState.Closed)) {
this.Adapter.InsertCommand.Connection.Close();
}
}
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[System.ComponentModel.DataObjectMethodAttribute(System.ComponentModel.DataObjectMethodType.Update, true)]
public virtual int Update(
string sid,
string sname,
string sex,
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -