I am using one controller which is inserting values in the database. I want to display alert message from controller when the values insertesd in the database successfully.
Is it possible. If yes then how?
I am using one controller which is inserting values in the database. I want
Share
Basically that depends on how are you inserting the value into the database, as you would need a method to tells you whether the insertion was successful. As there’s a few ways to do that now, linq/entity framework/sql/etc.
Then after you know whether did the insertion happens, then you can just assign a value to a variable and then from the code/aspx just check the value and do a simple alert.