CodeCharge Studio
search Register Login  

Web Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> Archive -> GotoCode Archive

 Session Variable in ASP

Print topic Send  topic

Author Message
Robert
Posted: 11/04/2003, 9:32 AM

Hi,
As you might already know I'm having difficulties with the Session variable in Code Charge 2.2.2.40 Trial version. based on theory of the Session object in ASP one should be able to have this simple statement :

Session("test")= "12" ' any_value test is just a variable which has not been declaired or defined anywhere

<%=Session("test")%>

I can run this code in a simple ASP file but it wont work in a Code Charge project generated ASP file. Is there any reason for that which I'm not aware?
I do appreciate if you could help me on this.
one more question, could Cold Fusion be a replacement for Code Charge? (I have no idea about it!)

Thank you,
Robert



Hamilton
Posted: 11/04/2003, 12:38 PM

You may be attempting to place the <%=Session("Test")%> code directly into the HTML page, which doesn't work under CCS methodology due to CCS using the File System Object.

Instead, place a label on the form and place your code inside of it on the "Before_Show()" Event.

Like this

The name of the Label is 'lblMySessionVar'

Dim sResult
sResult = Session("test")
lblMySessionVar.Value = sResult


Note: if the label is placed within a grid or recordset you need to prefix the last line with the name of the recordset.
e.g, myRecordset.lblMySessionVar.Value = sResult

Hope this helps

Robert
Posted: 11/04/2003, 4:05 PM

Thank you Hamilton, I'll give it a try.

Robert

   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

PHP Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.