[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

greatdane

7/11/2006 2:26:00 PM

A session is lost after a click of a button!

I am saving my typed dataset to a session:
Session.Add("ds_FPInfo_Group", Dataset11)

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load

'\\To retrieve the session variable'\If Page.IsPostBack Then
Dataset11 = CType(Session("ds_FPInfo_Group"),
Data.DataSet)
endif
end sub
The retrieve works well, but when I click on a cmdSave button, the
session is lost.
I have asked other developers in my group and we can not find the answer.
Appreciate your help!!

6 Answers

Alvin Bruney [ASP.NET MVP]

7/12/2006 2:36:00 AM

0

session is typically lost when the application pool recycles. have a look at
your event logs first to see if that is the reason.

--
________________________
Warm regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Professional VSTO.NET - Wrox/Wiley
The O.W.C. Black Book with .NET
www.lulu.com/owc, Amazon
Blog: http://www.msmvps.com/b...
-------------------------------------------------------


"greatdane" <greatdane@discussions.microsoft.com> wrote in message
news:911C1267-97AD-474B-9B31-2D9E2B97A9B3@microsoft.com...
>A session is lost after a click of a button!
>
> I am saving my typed dataset to a session:
> Session.Add("ds_FPInfo_Group", Dataset11)
>
> Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
> System.EventArgs) Handles MyBase.Load
>
> '\\To retrieve the session variable'\> If Page.IsPostBack Then
> Dataset11 = CType(Session("ds_FPInfo_Group"),
> Data.DataSet)
> endif
> end sub
> The retrieve works well, but when I click on a cmdSave button, the
> session is lost.
> I have asked other developers in my group and we can not find the answer.
> Appreciate your help!!
>


greatdane

7/12/2006 3:49:00 PM

0

This application test is stored in my local machine running xp Professional
and IIS5
I see the dataset populated after postback and at the command button the
dataset is null. It supposed to be in memory.

"Alvin Bruney [MVP]" wrote:

> session is typically lost when the application pool recycles. have a look at
> your event logs first to see if that is the reason.
>
> --
> ________________________
> Warm regards,
> Alvin Bruney [MVP ASP.NET]
>
> [Shameless Author plug]
> Professional VSTO.NET - Wrox/Wiley
> The O.W.C. Black Book with .NET
> www.lulu.com/owc, Amazon
> Blog: http://www.msmvps.com/b...
> -------------------------------------------------------
>
>
> "greatdane" <greatdane@discussions.microsoft.com> wrote in message
> news:911C1267-97AD-474B-9B31-2D9E2B97A9B3@microsoft.com...
> >A session is lost after a click of a button!
> >
> > I am saving my typed dataset to a session:
> > Session.Add("ds_FPInfo_Group", Dataset11)
> >
> > Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
> > System.EventArgs) Handles MyBase.Load
> >
> > '\\To retrieve the session variable'\> > If Page.IsPostBack Then
> > Dataset11 = CType(Session("ds_FPInfo_Group"),
> > Data.DataSet)
> > endif
> > end sub
> > The retrieve works well, but when I click on a cmdSave button, the
> > session is lost.
> > I have asked other developers in my group and we can not find the answer.
> > Appreciate your help!!
> >
>
>
>

Alvin Bruney [ASP.NET MVP]

7/13/2006 1:00:00 AM

0

it case you didn't catch my drift, run eventvwr at the command prompt and
have a look at the application logs for any application recycled message
errors that may appear.

--
________________________
Warm regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Professional VSTO.NET - Wrox/Wiley
The O.W.C. Black Book with .NET
www.lulu.com/owc, Amazon
Blog: http://www.msmvps.com/b...
-------------------------------------------------------


"greatdane" <greatdane@discussions.microsoft.com> wrote in message
news:5ED6A361-0B41-41A8-AC8F-C9A42F453311@microsoft.com...
> This application test is stored in my local machine running xp
> Professional
> and IIS5
> I see the dataset populated after postback and at the command button the
> dataset is null. It supposed to be in memory.
>
> "Alvin Bruney [MVP]" wrote:
>
>> session is typically lost when the application pool recycles. have a look
>> at
>> your event logs first to see if that is the reason.
>>
>> --
>> ________________________
>> Warm regards,
>> Alvin Bruney [MVP ASP.NET]
>>
>> [Shameless Author plug]
>> Professional VSTO.NET - Wrox/Wiley
>> The O.W.C. Black Book with .NET
>> www.lulu.com/owc, Amazon
>> Blog: http://www.msmvps.com/b...
>> -------------------------------------------------------
>>
>>
>> "greatdane" <greatdane@discussions.microsoft.com> wrote in message
>> news:911C1267-97AD-474B-9B31-2D9E2B97A9B3@microsoft.com...
>> >A session is lost after a click of a button!
>> >
>> > I am saving my typed dataset to a session:
>> > Session.Add("ds_FPInfo_Group", Dataset11)
>> >
>> > Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
>> > System.EventArgs) Handles MyBase.Load
>> >
>> > '\\To retrieve the session variable'\>> > If Page.IsPostBack Then
>> > Dataset11 = CType(Session("ds_FPInfo_Group"),
>> > Data.DataSet)
>> > endif
>> > end sub
>> > The retrieve works well, but when I click on a cmdSave button, the
>> > session is lost.
>> > I have asked other developers in my group and we can not find the
>> > answer.
>> > Appreciate your help!!
>> >
>>
>>
>>


GregoryHill

7/25/2006 5:07:00 PM

0

Can you be more specific about the application pool? Where, exactly, can we find the logs for the pool? I've looked (I think) in all the usual places, but am finding nothing.

Our application is suffering from (apparently) the same problem. If there is any kind of load on the server, beside the app itself, people get booted out of the app. I think I've narrowed it down to the loss of session info.

Any more thoughts?

GregoryHill

7/25/2006 5:20:00 PM

0

Can you be more specific about the application pool? Where, exactly, can we find the logs for the pool? I've looked (I think) in all the usual places, but am finding nothing.

Our application is suffering from (apparently) the same problem. If there is any kind of load on the server, beside the app itself, people get booted out of the app. I think I've narrowed it down to the loss of session info.

Any more thoughts?

Alvin Bruney [ASP.NET MVP]

7/26/2006 1:13:00 AM

0

run inetmgr from the command prompt expand default websites, application
pool will be there. This is only for IIS 6 on server 03.

run eventwr on the command prompt, examine the application logs for
application pool recylced messages. correlate the time with the problems you
are seeing.

--
________________________
Warm regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Professional VSTO.NET - Wrox/Wiley
The O.W.C. Black Book with .NET
www.lulu.com/owc, Amazon
Blog: http://www.msmvps.com/b...
-------------------------------------------------------


<Gregory Hill> wrote in message
news:emTKG6AsGHA.1580@TK2MSFTNGP05.phx.gbl...
> Can you be more specific about the application pool? Where, exactly, can
> we find the logs for the pool? I've looked (I think) in all the usual
> places, but am finding nothing.
>
> Our application is suffering from (apparently) the same problem. If there
> is any kind of load on the server, beside the app itself, people get
> booted out of the app. I think I've narrowed it down to the loss of
> session info.
>
> Any more thoughts?