Click here to Skip to main content
16,008,299 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionEvent Bubling Pin
specialdreamsin22-Mar-09 19:52
specialdreamsin22-Mar-09 19:52 
AnswerRe: Event Bubling Pin
N a v a n e e t h22-Mar-09 19:56
N a v a n e e t h22-Mar-09 19:56 
AnswerRe: Event Bubling Pin
Amrendra Singh124022-Mar-09 23:09
Amrendra Singh124022-Mar-09 23:09 
QuestionRefresh problem.... Pin
RajpootRohan22-Mar-09 19:31
professionalRajpootRohan22-Mar-09 19:31 
AnswerRe: Refresh problem.... Pin
N a v a n e e t h22-Mar-09 19:34
N a v a n e e t h22-Mar-09 19:34 
GeneralRe: Refresh problem.... Pin
RajpootRohan22-Mar-09 19:42
professionalRajpootRohan22-Mar-09 19:42 
GeneralRe: Refresh problem.... Pin
N a v a n e e t h22-Mar-09 19:53
N a v a n e e t h22-Mar-09 19:53 
AnswerRe: Refresh problem.... Pin
Deepak the Cool22-Mar-09 20:36
Deepak the Cool22-Mar-09 20:36 
Hi

Just Copy Paste the following Code into your page. This is my research into internet on fresher level.....

private bool _refreshState;
public bool _isRefresh;
public bool IsRefresh //
{
get
{
return _isRefresh;//get the value of Refresh click from Internet Explorer
}
}
protected override object SaveViewState()
{
Session["_ISREFRESH"] = _refreshState; //define Session variable and intilize
object[] allstates = new object[2]; //Define object array named allstates
allstates[0] = base.SaveViewState(); //get the base.SaveViewState in allstate array at 0 position
allstates[1] = !_refreshState; //get the allstate array at 1 position from !_refreshState
return allstates;
}
protected override void LoadViewState(object savedState)//function for LoadViewState
{
object[] allstates = (object[])savedState; //Parsing saveState value at allsataes object array
base.LoadViewState(allstates[0]); //Loading viewState value
_refreshState = (bool)allstates[1];
if (Session["_ISREFRESH"] != null)
{
if (_refreshState == (bool)Session["_ISREFRESH"])
_isRefresh = true;
}
else
{ }
}

And use it into your insert operation
protected void btnInsert_Click(object sender, EventArgs e)
{
if (!_isRefresh)
{
Your Insert Operations here...
}

}

Deepak

Smile | :) Smile a Lots,Its Costs Nothing

GeneralRe: Refresh problem.... Pin
N a v a n e e t h22-Mar-09 20:47
N a v a n e e t h22-Mar-09 20:47 
QuestionLocal Printing on ASP.NET Pin
seenubhai22-Mar-09 19:07
seenubhai22-Mar-09 19:07 
AnswerRe: Local Printing on ASP.NET Pin
N a v a n e e t h22-Mar-09 19:31
N a v a n e e t h22-Mar-09 19:31 
AnswerLocal Printing on ASP.NET Pin
seenubhai22-Mar-09 20:12
seenubhai22-Mar-09 20:12 
GeneralRe: Local Printing on ASP.NET Pin
prateekfgiet23-Mar-09 22:14
prateekfgiet23-Mar-09 22:14 
QuestionSession Problem Pin
specialdreamsin22-Mar-09 18:22
specialdreamsin22-Mar-09 18:22 
AnswerRe: Session Problem Pin
N a v a n e e t h22-Mar-09 19:30
N a v a n e e t h22-Mar-09 19:30 
GeneralRe: Session Problem Pin
specialdreamsin22-Mar-09 19:39
specialdreamsin22-Mar-09 19:39 
GeneralRe: Session Problem Pin
N a v a n e e t h22-Mar-09 19:50
N a v a n e e t h22-Mar-09 19:50 
Questionaccessing asp:textbox with javascripts Pin
AprNgp22-Mar-09 7:15
AprNgp22-Mar-09 7:15 
AnswerRe: accessing asp:textbox with javascripts Pin
Christian Graus22-Mar-09 10:21
protectorChristian Graus22-Mar-09 10:21 
AnswerRe: accessing asp:textbox with javascripts Pin
vinodkrebc22-Mar-09 18:30
vinodkrebc22-Mar-09 18:30 
QuestionValue Transfer From pop-up Window to Main Window!! Pin
Sr...Frank22-Mar-09 4:54
Sr...Frank22-Mar-09 4:54 
AnswerRe: Value Transfer From pop-up Window to Main Window!! Pin
N a v a n e e t h22-Mar-09 5:09
N a v a n e e t h22-Mar-09 5:09 
GeneralRe: Value Transfer From pop-up Window to Main Window!! Pin
Sr...Frank22-Mar-09 6:03
Sr...Frank22-Mar-09 6:03 
GeneralRe: Value Transfer From pop-up Window to Main Window!! Pin
Yusuf22-Mar-09 6:06
Yusuf22-Mar-09 6:06 
GeneralRe: Value Transfer From pop-up Window to Main Window!! Pin
Sr...Frank22-Mar-09 7:25
Sr...Frank22-Mar-09 7:25 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.