本文整理汇总了C#中DataBaseHelper.Run方法的典型用法代码示例。如果您正苦于以下问题:C# DataBaseHelper.Run方法的具体用法?C# DataBaseHelper.Run怎么用?C# DataBaseHelper.Run使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类DataBaseHelper
的用法示例。
在下文中一共展示了DataBaseHelper.Run方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Add
public void Add()
{
_showcaseInsertDataParameters = new ShowcaseInsertDataParameters(PageId, ProductId);
DataBaseHelper dbHelper = new DataBaseHelper(StoredProcedureName);
dbHelper.Parameters = _showcaseInsertDataParameters.Parameters;
dbHelper.Run();
}
示例2: Add
public void Add()
{
_shoppingCartInsertDataParameters = new ShoppingCartInsertDataParameters(ShoppingCart);
DataBaseHelper dbHelper = new DataBaseHelper(StoredProcedureName);
dbHelper.Parameters = _shoppingCartInsertDataParameters.Parameters;
dbHelper.Run();
}
示例3: GetReverseGeocoding
public void GetReverseGeocoding()
{
DataBaseHelper _db = new DataBaseHelper(Command, CommandType.StoredProcedure);
DataSet ds = new DataSet();
try
{
// Use the reverse geocoding database connection string. VERY IMPORTANT so
// Reverse Geocoding will work!
ds = _db.Run(base.RGConnectionString, ReturnParams());
if (ds.Tables[0].Rows.Count > 0) {
// Get the postal code
postalCode = ds.Tables[0].Rows[0]["postalCode"].ToString();
// Get the city
city = ds.Tables[0].Rows[0]["placeName"].ToString();
// Get the county
county = ds.Tables[0].Rows[0]["adminName2"].ToString();
// Get the state
state = ds.Tables[0].Rows[0]["adminName1"].ToString();
// Get the country
country = ds.Tables[0].Rows[0]["countryCode"].ToString();
}
}
catch (Exception ex)
{
throw new Exception(" AlarmasABC.DAL.ReverseGeocoding:: " + ex.Message);
}
finally
{
_db = null;
}
}
示例4: saveSchemePermission
public int saveSchemePermission()
{
DataSet _ds = new DataSet();
try
{
DataBaseHelper _db =new DataBaseHelper(Command, CommandType.StoredProcedure);
_ds= _db.Run(base.ConnectionString,returnParam());
}
catch (Exception ex)
{
throw new Exception(ex.Message.ToString());
}
finally
{
}
if (_ds.Tables[0].Rows.Count > 0)
{
return int.Parse(_ds.Tables[0].Rows[0][0].ToString());
}
else
{
return -1;
}
}
示例5: Delete
public void Delete()
{
_shoppingCartByGuidDeleteDataParameters = new ShoppingCartByGuidDeleteDataParameters(ShoppingCart);
DataBaseHelper dbHelper = new DataBaseHelper(StoredProcedureName);
dbHelper.Parameters = _shoppingCartByGuidDeleteDataParameters.Parameters;
dbHelper.Run();
}
示例6: GetAlert
public void GetAlert()
{
DataBaseHelper _db = new DataBaseHelper(Command, CommandType.Text);
try
{
DataSet _ds;
_ds = _db.Run(base.ConnectionString, ReturnParams());
_alert.AlertTime = _alertTime;
if (_ds.Tables[0].Rows.Count > 0) {
_alert.AlertType = _ds.Tables[0].Rows[0]["alertType"].ToString();
_alert.AlertMessage =_ds.Tables[0].Rows[0]["alertMessage"].ToString();
} else {
_alert.AlertType = "None";
_alert.AlertMessage = "";
}
}
catch (Exception ex)
{
throw new Exception("AlarmasABC.DAL.AlertSelect: " + ex.Message);
}
finally
{
_db = null;
}
}
示例7: Update
public void Update()
{
_newsletterUpdateDataParameters = new NewsletterUpdateDataParameters(EndUser);
DataBaseHelper dbHelper = new DataBaseHelper(StoredProcedureName);
dbHelper.Parameters = _newsletterUpdateDataParameters.Parameters;
dbHelper.Run();
}
示例8: Update
public void Update()
{
_productUpdateDataParameters = new ProductUpdateDataParameters(Product, StockLevels);
DataBaseHelper dbHelper = new DataBaseHelper(StoredProcedureName);
dbHelper.Parameters = _productUpdateDataParameters.Parameters;
dbHelper.Run();
}
示例9: Get
public DataSet Get()
{
DataSet ds;
DataBaseHelper dbHelper = new DataBaseHelper(StoredProcedureName);
ds = dbHelper.Run(ConnectionString);
return ds;
}
示例10: Get
public DataSet Get()
{
DataSet ds;
ProductsSelectBySubCategoryIdDataParameters _productSelectPatameters = new ProductsSelectBySubCategoryIdDataParameters(SubCategoryId);
DataBaseHelper dbHelper = new DataBaseHelper(StoredProcedureName);
ds = dbHelper.Run(ConnectionString, _productSelectPatameters.Parameters);
return ds;
}
示例11: Get
public DataSet Get()
{
DataSet ds;
ShoppingCartSelectDataParameters _shoppingCartSelectDataParameters = new ShoppingCartSelectDataParameters(ShoppingCart);
DataBaseHelper dbHelper = new DataBaseHelper(StoredProcedureName);
ds = dbHelper.Run(base.ConnectionString, _shoppingCartSelectDataParameters.Parameters);
return ds;
}
示例12: Get
public DataSet Get()
{
DataSet ds;
ProductSelectByProductIdDataParamters _productSelectByIdParameters = new ProductSelectByProductIdDataParamters(Product);
DataBaseHelper dbHelper = new DataBaseHelper(StoredProcedureName);
ds = dbHelper.Run(base.ConnectionString, _productSelectByIdParameters.Parameters);
return ds;
}
示例13: Get
public DataSet Get()
{
DataSet ds;
ProductsSelectByNameDataParameters _productSelectByNameParameters = new ProductsSelectByNameDataParameters(ProductName, ProductColourId);
DataBaseHelper dbHelper = new DataBaseHelper(StoredProcedureName);
ds = dbHelper.Run(base.ConnectionString, _productSelectByNameParameters.Parameters);
return ds;
}
示例14: Get
public DataSet Get()
{
DataSet ds;
ShowcaseSelectByPageIdDataParameters _shocaseSelectByPageIdParameters = new ShowcaseSelectByPageIdDataParameters(PageId);
DataBaseHelper dbHelper = new DataBaseHelper(StoredProcedureName);
ds = dbHelper.Run(base.ConnectionString, _shocaseSelectByPageIdParameters.Parameters);
return ds;
}
示例15: Get
public DataSet Get()
{
DataSet ds;
EndUserLoginSelectDataParameters _endUserSelectDataParameters = new EndUserLoginSelectDataParameters(EndUser);
DataBaseHelper dbHelper = new DataBaseHelper(StoredProcedureName);
ds = dbHelper.Run(base.ConnectionString, _endUserSelectDataParameters.Parameters);
return ds;
}