本文整理汇总了C#中System.Web.UI.WebControls.FormViewInsertedEventArgs类的典型用法代码示例。如果您正苦于以下问题:C# FormViewInsertedEventArgs类的具体用法?C# FormViewInsertedEventArgs怎么用?C# FormViewInsertedEventArgs使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
FormViewInsertedEventArgs类属于System.Web.UI.WebControls命名空间,在下文中一共展示了FormViewInsertedEventArgs类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: contactInsert
protected void contactInsert(object sender, FormViewInsertedEventArgs e)
{
if (e.AffectedRows == 1)
{
Response.Redirect("index.aspx");
}
}
示例2: uxFormView_ItemInserted
protected void uxFormView_ItemInserted(object sender, FormViewInsertedEventArgs e)
{
////get user id
//MembershipUser usr = Membership.GetUser();
//Guid uid = (Guid)usr.ProviderUserKey;
////setup database connection
//SqlConnection connection = new SqlConnection(ConfigurationManager.ConnectionStrings["DB_MYCHURCH"].ConnectionString);
////setup a way to talk to the database
//SqlCommand command = new SqlCommand();
//command.Connection = connection;
//try
//{
// command.Connection.Open();
// command.CommandType = CommandType.StoredProcedure;
// command.CommandText = "ChurchWorkers_Insert";
// command.Parameters.Add(new SqlParameter("@UserId", uid));
// command.ExecuteNonQuery();
//}
//catch
//{
//}
//finally
//{
// command.Connection.Close();
//}
}
示例3: FormViewTipoCampi_ItemInserted
protected void FormViewTipoCampi_ItemInserted(object sender, FormViewInsertedEventArgs e)
{
if (e.Exception == null)
Response.Redirect(lblPreviousPage.Text);
else
lblError.Text = e.Exception.Message;
}
示例4: formView_ItemInserted
protected void formView_ItemInserted(object sender, FormViewInsertedEventArgs e)
{
if (e.Exception == null)
{
Response.Redirect(string.Format("~/UI/ShipperDetailForm.aspx?id={0}", _lazyItem.Reference.ShipperID));
}
}
示例5: FormView1_ItemInserted
protected void FormView1_ItemInserted(object sender, FormViewInsertedEventArgs e)
{
if (e.Exception == null || e.ExceptionHandled)
{
Response.Redirect(table.ListActionPath);
}
}
示例6: attractionsForm_ItemInserted
protected void attractionsForm_ItemInserted(object sender, FormViewInsertedEventArgs e)
{
{
Response.Redirect("~/WebForms");
}
}
示例7: FormViewTipo_ItemInserted
protected void FormViewTipo_ItemInserted(object sender, FormViewInsertedEventArgs e)
{
string sIDFormTipo = ReturnMaxValueTable("FormTipo", "IDFormTipo", new SqlConnection(SqlDataSourceGat2.ConnectionString)).ToString();
Response.Redirect("~/RefertiConfiguration.aspx?IDFormTipo=" + sIDFormTipo);
}
示例8: regInsert
protected void regInsert(object sender, FormViewInsertedEventArgs e)
{
if (e.AffectedRows == 1)
{
Session["user"] = e.Values["name"];
Response.Redirect("index.aspx");
}
}
示例9: FormView1_ItemInserted
protected void FormView1_ItemInserted(object sender, FormViewInsertedEventArgs e)
{
GridView1.DataBind();
btneditar.Visible = false;
btneliminar.Visible = false;
}
示例10: FormView2_ItemInserted1
protected void FormView2_ItemInserted1(object sender, FormViewInsertedEventArgs e)
{
FormView3.DataBind();
using (FinanceManagerDataContext db = new FinanceManagerDataContext())
{
Member _member = db.Members.FirstOrDefault(m => m.MemberId == Convert.ToInt32(Request.QueryString["mid"]));
//int investmentTypeID = ( db.Investments.FirstOrDefault(i => i.InvestmentID == Convert.ToInt32( Request.QueryString["InvId"])).InvestmentTypeId.Value);
//AccountType accType = db.AccountTypes.FirstOrDefault(a => a.DefaultInvestmentTypeID == investmentTypeID);
//withdrawal
List<AccountTypeFeature> aFeatures = _member.AccountType.AccountTypeFeatures.Where(a => a.CalculateOn == 2).ToList();
foreach (AccountTypeFeature item in aFeatures)
{
decimal valueToApply = 0;
if (item.IsPercentage.Value)
{
valueToApply = item.ValueToApply.Value / 100 * Convert.ToDecimal(Session["WithdrawnAmount"]);
}
else
{
valueToApply = item.ValueToApply.Value;
}
if (item.IsDeduction.Value) //is deduction
{
AppliedDeduction aDeduction = new AppliedDeduction();
aDeduction.CreatedBy = User.Identity.Name;
aDeduction.CreatedDate = DateTime.Now;
aDeduction.DeductionAmount = valueToApply;
aDeduction.InvestmentID = Convert.ToInt32(Request.QueryString["InvId"]);
//aDeduction.IsDeleted = false;
aDeduction.Rate = item.ValueToApply;
db.AppliedDeductions.InsertOnSubmit(aDeduction);
}
else //is addition
{
AppliedInterest aInterest = new AppliedInterest();
aInterest.CreatedBy = User.Identity.Name;
aInterest.CreatedDate = DateTime.Now;
aInterest.InterestAmount = valueToApply;
aInterest.InvestmentID = Convert.ToInt32(Request.QueryString["InvId"]);
//aDeduction.IsDeleted = false;
aInterest.Rate = item.ValueToApply;
db.AppliedInterests.InsertOnSubmit(aInterest);
}
db.SubmitChanges();
////AppliedAccountFeature aAccountFeature = new AppliedAccountFeature();
////aAccountFeature.InvestmentID = Convert.ToInt32(Request.QueryString["InvId"]);
////aAccountFeature.AccountNumber =
}
}
}
示例11: FormViewAssistenza_ItemInserted
protected void FormViewAssistenza_ItemInserted(object sender, FormViewInsertedEventArgs e)
{
if (e.Exception == null)
{
if (GestioneCaricamentoCalendario())
Response.Redirect("~/Assistenze/AssistenzaListGroupSingolaZona.aspx");
}
else
{
lblError.Text = e.Exception.Message;
}
}
示例12: FormView1_ItemInserted
protected void FormView1_ItemInserted(object sender, FormViewInsertedEventArgs e)
{
if(e.Exception != null)
{
System.Diagnostics.Debug.WriteLine("Need to handle the error.");
e.ExceptionHandled = true;
}
else
{
System.Diagnostics.Debug.WriteLine("That was fine");
}
}
示例13: FormView1_ItemInserted
protected void FormView1_ItemInserted(object sender, FormViewInsertedEventArgs e)
{
if (e.Exception == null || e.ExceptionHandled)
{
Response.Redirect(_table.ListActionPath);
}
else
{
ShowMessage(e.Exception);
e.ExceptionHandled = true;
}
}
示例14: OnItemInserted
protected void OnItemInserted(object sender, FormViewInsertedEventArgs e)
{
if (e.Exception == null)
{
Utilities.WriteWindowClose();
}
else
{
Utilities.OnError(Page, false, e.Exception);
e.KeepInInsertMode = true;
e.ExceptionHandled = true;
}
}
示例15: FormView1_ItemInserted
protected void FormView1_ItemInserted(object sender, FormViewInsertedEventArgs e)
{
//if (e.Exception == null || e.ExceptionHandled)
//{
// e.Values
// //Response.Write("Linking to: " + Request["linkto"]);
// Response.Redirect(table.GetActionPath("Details", DataItem));
// //Response.Redirect("Details.aspx?id=asdf");
//}
//else
//{
// ShowError(e.Exception.ToString());
//}
}