"景先生毕设|www.jxszl.com

C# DataRow类代码示例

2023-12-29 17:49编辑: www.jxszl.com景先生毕设
本文整理汇总了C#中DataRow类的典型用法代码示例。如果您正苦于以下问题:C#DataRow类的具体用法?C#DataRow怎么用?C#DataRow使用的例子?这里精选的类代码示例或许可以为您提供帮助。 示例1:DetermineStudentRecipientCount protectedInt32DetermineStudentRecipientCount(DataRowCriteriaRow) { System.Text.StringBuildersbSQL=newSystem.Text.StringBuilder(); sbSQL.Append("selectcount(portfolioid)fromPortfolioUserInfowhereactive=1andConSysID="+_ConSysID); //Gender stringstrGenderSQL=RemoveTrailingComma(CriteriaRow["Cri_Gender"].ToString()); stringstrGradeSQL=RemoveTrailingComma(CriteriaRow["Cri_Grades"].ToString()); stringstrCountySQL=RemoveTrailingComma(CriteriaRow["Cri_Counties"].ToString()); stringstrSchoolSQL=RemoveTrailingComma(CriteriaRow["Cri_Schools"].ToString()); stringstrCareerSQL=RemoveTrailingComma(CriteriaRow["Cri_Careers"].ToString()); stringstrClusterSQL=RemoveTrailingComma(CriteriaRow["Cri_Clusters"].ToString()); stringstrCompanySQL=""; if(_MessageTypeID==3) strCompanySQL=(CriteriaRow["Cri_Company"].ToString()=="True")?CriteriaRow["CompanyID"].ToString():""; if((strGenderSQL!="All")&&(strGenderSQL.Trim()!="1,0")) sbSQL.Append("andGenderIDin("+strGenderSQL+")"); if(strGradeSQL!="All") sbSQL.Append("andGradeNumberin("+strGradeSQL+")"); if(strSchoolSQL!="All") sbSQL.Append("andSchoolIDin("+strSchoolSQL+")"); if(strCountySQL!="All") sbSQL.Append("andCountyIDin("+strCountySQL+")"); if(strCareerSQL!="All") sbSQL.Append("andPortfolioIDin(SelectPortfolioIDfromPort_SavedCareerswhereOccNumberin("+strCareerSQL+"))"); if(strClusterSQL!="All") sbSQL.Append("andPortfolioIDin(SelectPortfolioIDfromPort_ClusterInterestswhereClusterIDin("+strClusterSQL+"))"); if(strCompanySQL.Length>0) sbSQL.Append("andPortfolioIDin(SelectPortfolioIDfromPort_SavedCompanieswhereCompanyID="+strCompanySQL+")"); stringstrTempCount=CareerCruisingWeb.CCLib.Common.DataAccess.GetValue(sbSQL.ToString()).ToString(); returnConvert.ToInt32(strTempCount); }
原文链接:http://www.jxszl.com/biancheng/C/556877.html