Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Session.Abandon issue!!!

Status
Not open for further replies.

middlename

Programmer
Mar 14, 2003
16
0
0
US
I use ASP pages With RDC to post Crystal Reports over a Web. Everything works fine, until I realized that I cannot use "Back" button. It destroys all session variable I need in my application!
CR require include Clinup.asp page with this code:

'The JavaScript code is used to close the newly opened browser window once the page has run
Session.Abandon
Response.End
'These last two lines terminate that user's active session and flushes html to the browser.


So,.. session.abandon is my problem! I cannot commented it out, because it is CR license issue, but it is killing all session variables!!??

What should I do???

Thank you for any help!!!
 
There is a way to destroy certain session variables with asp instead of everything... but I can't recall the details. I'd try posting a question to the asp forum on how to do this. There are countless other asp referances on line as well. You could also store the log in info in a cookie on the users computer. When returning to view the report, check to see if the log in credentials exist in a session variable. If they don't, set the session variables to equal the values you saved in your cookie, and then log in. If there is no cookie, redirect to a log in page.

Good luck!
 
Thank you!

The problem is I don't want users to log in every time they print single report.
 
You can either save the session variable with this info, or reset the session variable using a cookie on the users machine to reset session variable, allowing them to log back in without knowing it.
 
Thanks alot!
I am not really familiar with cookies, so
how secure it is using cookies?
Is it alternative to using session variables?

Thank you.
 
Hello Middlename!
I have the same problem with loosing all session variables in my app then I returned to other pages from reportpreview.
Have you solved a problem?
There is an article about this problem
"How do I remove a session variable from memory in an ASP application?
"
We should change the cleanup.asp according to this article. Please let me know the location of cleanup.asp
 
Hello Just4fun!
I use cookies instead of session variables and open another window for report. So far it works fine!
But seems there is another way to do it, according this article. I will try it.(Thank you for this link!)
My cleanup.asp is in the same directory where is a report file.
By the way, did you try the method Crystal Care recomended?
 
Hello Middlename!
Unfortunately I do not have the cleanup.asp on my system. I worked with Crystal Report Enterprise Edition 8.0 and ActiveX Viewer.
I solved the problem by saving the session variables in the ini file and restoring them in the new session. This way does not require the new window to be opened.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top