473,387 Members | 1,791 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

losing value from session

Hi,

I am using ASP.Net with C#. My application is using a control and when
control object is created my application set all the values to that
control. This also contain connection string values. Control add
connection string to session and rest values send to second application
in XML format. Second application does some processing and return back
to control. Here my control have to insert the return data to database
but when I try to access the connection string from session its empty.
Can anyone help me how I can keep the values.

My application is call to second appcation and this second application
is completly seprate application (some jsp/java)

Thanks in advance.

Sukh

Jan 3 '06 #1
6 1859
Maybe better to keep your connection string in the web.config file. But as
to why your session variables are disappearing - how are you calling the
second application? Could it be that a second session is being created?

"Sukh" <su*********@gmail.com> wrote in message
news:11*********************@g14g2000cwa.googlegro ups.com...
Hi,

I am using ASP.Net with C#. My application is using a control and when
control object is created my application set all the values to that
control. This also contain connection string values. Control add
connection string to session and rest values send to second application
in XML format. Second application does some processing and return back
to control. Here my control have to insert the return data to database
but when I try to access the connection string from session its empty.
Can anyone help me how I can keep the values.

My application is call to second appcation and this second application
is completly seprate application (some jsp/java)

Thanks in advance.

Sukh

Jan 3 '06 #2
Hi Sosh,
we are keeping con string in web.config file but when appliction
setting the control values so it set con string values at same time.
second appliction calling usin Response.Redirect ("http..."). its
completely seprate app. and hosted on different server....
I checked its creating second session..
is therea any way to work around...??
Thanks.
Sukh

Jan 3 '06 #3
Hmm. If I understand you correctly:

I take it that the client needs to interact with the JSP app in some way,
and thats why you are using Response.Redirect, if not (and it just needs to
do some extra server side processing or something) then it might be better
to implement the second app as some kind of webservice, and call it from the
code behind in the first app.

If the client does need to interact with the JSP app, then you would somehow
need to pass a session refference to the JSP app, and have it pass it back
in the correct way when its done. Cookieless sessions may help here (where
the session id is part of the URL), you could possibly construct a URL to
pass control back to with the correct session id format - but it sounds a
bit messy. Maybe someone else knows a better way.

Good luck

"Sukh" <su*********@gmail.com> wrote in message
news:11**********************@g14g2000cwa.googlegr oups.com...
Hi Sosh,
we are keeping con string in web.config file but when appliction
setting the control values so it set con string values at same time.
second appliction calling usin Response.Redirect ("http..."). its
completely seprate app. and hosted on different server....
I checked its creating second session..
is therea any way to work around...??
Thanks.
Sukh

Jan 3 '06 #4
How log is it between when you redirect to the second app and then go back
to the first? It sounds like the first application's session is timing out.

I agree with Sosh's suggestion of converting the second app to a web service
if it has no user interaction component to it.
Otherwise, you might need to increase session timeout, if this is a timing
issue.

"Sukh" <su*********@gmail.com> wrote in message
news:11*********************@g14g2000cwa.googlegro ups.com...
Hi,

I am using ASP.Net with C#. My application is using a control and when
control object is created my application set all the values to that
control. This also contain connection string values. Control add
connection string to session and rest values send to second application
in XML format. Second application does some processing and return back
to control. Here my control have to insert the return data to database
but when I try to access the connection string from session its empty.
Can anyone help me how I can keep the values.

My application is call to second appcation and this second application
is completly seprate application (some jsp/java)

Thanks in advance.

Sukh

Jan 3 '06 #5
Hi Marina,
I can't change second appliction coz that's one of our other agency. We
hv to pass some data to them and on the basis to our data they do some
processing and return back to our appl.
Here I am working on a control which is going to use by three differnt
application so I exposing some properties so client application can set
the values.
I wanna to make it configureable.
Its not timeout issue. Actually when application comes back from the
second application it generates new session .

Jan 3 '06 #6
You still did not say whether the second application has any user
interaction/forms or not, though both myself and Sosh asked.

If it does not require user interaction, you can make an HttpWebRequest to
the second application from the server side code of the first one. This is
essentially like the poor man's web service. You make the request to the
second application to a particular page, it returns a response. You process
the response, and continue on - and you never redirected the user anywhere
at all.

"Sukh" <su*********@gmail.com> wrote in message
news:11**********************@o13g2000cwo.googlegr oups.com...
Hi Marina,
I can't change second appliction coz that's one of our other agency. We
hv to pass some data to them and on the basis to our data they do some
processing and return back to our appl.
Here I am working on a control which is going to use by three differnt
application so I exposing some properties so client application can set
the values.
I wanna to make it configureable.
Its not timeout issue. Actually when application comes back from the
second application it generates new session .

Jan 3 '06 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Scott Lyon | last post by:
I'm maintaining (read: I didn't write it, nor do I have the time to spend to rewrite it) an application that is suddenly giving me grief. The reason I say suddenly, is because we're in the...
4
by: Stephen | last post by:
I have a .NET (1.1 framework) application that is losing a session variable on only a few PC's. The main page is loading up in a frame in a Portal application. On the Page_Load it stores an...
1
by: Werner | last post by:
Hi Patrick! Can you give an example of how to use a frameset inside an aspx-file? When I create a new frameset in Visual Studio.Net it just gives me a htm-File. Or give me a link where I can...
4
by: Keith-Earl | last post by:
I have been writing ASP.NET apps since the RTM build and have never seen this. I built a simple app that uses session variables on my DEV laptop. All runs well. I have a simple toggle routine...
5
by: fbwhite | last post by:
I know this issue has been brought up many times, but I have tried many of the solutions to no avail. I wanted to give my specific case to see if someone could be of any help. We are using the...
9
by: Adrian Parker | last post by:
We have a website that works everywhere but on a few PCs on this one site.. Asp.Net 1.1 Server = Windows 2003 Client = XP In the web.config we use - cookieless="false" in the browser settings...
0
by: Jimmy Reds | last post by:
Hi, Sorry if this appears twice but I post through Google Groups and it had a funny 5 minutes and didn't appear to post this message the first time. I am setting session variables on a page...
2
by: Jimmy Reds | last post by:
Hi, I am setting session variables on a page then doing a header/location redirect to a second page however I am losing one of my session variables. Not all of them, just one. Here are some...
0
by: none | last post by:
Hi, I've got a problem with losing session state in ASP.NET version 2. It does it intermittently - sometimes it tanks - and sometimes it works OK. I've got the ASP.NET state service started...
5
by: chromis | last post by:
Hi there, I've recently been updating a site to use locking on application level variables, and I am trying to use a commonly used method which copies the application struct into the request...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.