Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7613335
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T02:07:50+00:00 2026-05-31T02:07:50+00:00

My code is executing the OnItemInserting function but not the OnItemInserted. Have I declared

  • 0

My code is executing the OnItemInserting function but not the OnItemInserted. Have I declared the Inserted function correctly?

aspx

<asp:FormView ID="FormView1" runat="server" DefaultMode="Insert" OnItemInserting="Insert" OnItemInserted="Inserted">

vb

Protected Sub Insert(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.FormViewInsertEventArgs) Handles FormView1.ItemInserting
' Works
End Sub


Protected Sub Inserted(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.FormViewInsertedEventArgs) Handles FormView1.ItemInserted
    Response.Redirect("Login.aspx") ' Never gets here
End Sub

The code never enters the Inserted function and just refreshes the form after executing the Insert

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T02:07:51+00:00Added an answer on May 31, 2026 at 2:07 am

    ItemInserted event will be raised only if FormView is data-bound and the data-source handles the insert (and subsequently call backs the control after insert).

    I suspect that you have not bound your form-view to any data source control (such as SqlDataSource). In case, you are planning to handle inserting into the data-store by writing custom code then you should do that part in ItemInserting event itself.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We have C# application that crawling and executing code. But some time system stolp
I am getting error trying to run my asp code for executing stored proc.
I am executing below code successfully without any errors but when I am executing
Having some issues with code not executing within the classes I created and thought
I know that Apple's terms for apps disallows downloading and executing code, but there
I am writting like that in asp.net2.0 .cs file , after executing code disply
I have a piece of lua code (executing in Corona): local loginstr = emailAddress={email}
how to stop executing code in thread if takes to long. I have few
I want to perform a printf() to display when the currently executing code was
I'm executing this code: void update_process(PROCSP * process){ int state; printf(process.pid = %d\n, process->pid);

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.