Important alert: (current site time 7/15/2013 8:39:38 AM EDT)
 

VB icon

AnjaniSession

Email
Submitted on: 1/23/2006 7:29:29 PM
By: anjani kumar thakur  
Level: Intermediate
User Rating: Unrated
Compatibility: C#, VB.NET, ASP.NET, C++.NET
Views: 9147
(About the author)
 
     The session object that never expires nad still takes the minimum resource on server. 1. Anjani session is a revolutionary component which helps you fight from expiriing session. 2. It helps you do decrease your server load by helping you to keep the session time of 4 or 5 minutes instead of 20 minutes. 3. It automaticaly mange your session object on client insteade of server. 4. prity good for the session based websites. 5. You will have to abandon it manualy. 6. however the session is removed from the server with the specified timeout. 7. it helps you make your server resource free. 8. depends upon cookies as well as some hidden file to maintain the session at the client. 9.For user authentication purpose and logout a session.abandon property is given. 10.its not a rocket science but still something that you will like. 11.you can use it any of your dotnet application ERP application to fight with Managing server load,Page expirations as well as better resource management.
 
Can't Copy and Paste this?
Click here for a copy-and-paste friendly version of this code!
//**************************************
// for :AnjaniSession
//**************************************
This is a free dll to help you in your work.
 its tested but anjani kumar takes no guarantee or responsibility if it harms you or your work any way.
so plaese test it according to your condition and then use it if you want.
Code is free to use but source code rights reserved to anjnai kumar thakur of belbanwa motihari bihar india. +919868068154
anjanihardy@gmail.com
http://www.anjanihardy.cjb.net/index.htm
code:
Can't Copy and Paste this?
Click here for a copy-and-paste friendly version of this code!
 
Terms of Agreement:   
By using this code, you agree to the following terms...   
  1. You may use this code in your own programs (and may compile it into a program and distribute it in compiled format for languages that allow it) freely and with no charge.
  2. You MAY NOT redistribute this code (for example to a web site) without written permission from the original author. Failure to do so is a violation of copyright laws.   
  3. You may link to this code from another website, but ONLY if it is not wrapped in a frame. 
  4. You will abide by any additional copyright restrictions which the author may have placed in the code or code's description.
				
//**************************************
// Name: AnjaniSession
// Description:The session object that never expires nad still takes the minimum resource on server.
1. Anjani session is a revolutionary component which helps you fight from expiriing session.
2.
It helps you do decrease your server load by helping you to keep the session time of 4 or 5 minutes instead of 20 minutes.
3. It automaticaly mange your session object on client insteade of server.
4. prity good for the session based websites.
5. You will have to abandon it manualy.
6. however the session is removed from the server with the specified timeout.
7. it helps you make your server resource free.
8. depends upon cookies as well as some hidden file to maintain the session at the client.
9.For user authentication purpose and logout a session.abandon property is given.
10.its not a rocket science but still something that you will like.
11.you can use it any of your dotnet application ERP application to fight with Managing server load,Page expirations as well as better resource management.
// By: anjani kumar thakur
//
// Inputs:This is a component which can be easily used
you have to add areference to your project of the provided DLL and then use it.
//
// Returns:returns nothing. its the same way as you put a data in session and the retrieve it.
//
// Assumes:The user must know object oriented programming and asp.net.or atleast how to use objects.
//
// Side Effects:Till yet not found.
//
//This code is copyrighted and has// limited warranties.Please see http://www.Planet-Source-Code.com/vb/scripts/ShowCode.asp?txtCodeId=4435&lngWId=10//for details.//**************************************

dowonload code and samples from
http://www.devalt.org/asktheexpertforserver/resource/sessioncomponent.zip
password is ram
I am giving you the code sample showing how to use anjanisession
Below is page 1
Public Class WebForm1
Inherits System.Web.UI.Page
#Region " Web Form Designer Generated Code "
'This call is required by the Web Form Designer.
<System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()
End Sub
'NOTE: The following placeholder declaration is required by the Web Form Designer.
'Do not delete or move it.
Private designerPlaceholderDeclaration As System.Object
Private Sub Page_Init(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Init
'CODEGEN: This method call is required by the Web Form Designer
'Do not modify it using the code editor.
InitializeComponent()
End Sub
#End Region
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
'Put user code to initialize the page here
Response.Write("here we have creatted two session one with hardy sesion and another simple session then did session.abandon go to webform2 to see the result ")
' define the anjanisession object
' and now use the hardysession property to set the session
'to abandon use abandon property to abandon
' the examle below sets a session object with anjanisession and with the simple session
' after session.abandon or timeout general session expires but hardysession does not expire
' you will have to expire it by using anjanisession.abandon property
'for difficulty call anjanihardy@gmail.com or +919868068154
Dim x As New AnjaniSession.anjaniSession
x.hardysession("ram") = "ramesh"
Session("r") = "radheyshyam"
Session.Abandon()
End Sub
End Class
Page 2
Public Class WebForm2
Inherits System.Web.UI.Page
#Region " Web Form Designer Generated Code "
'This call is required by the Web Form Designer.
<System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()
End Sub
'NOTE: The following placeholder declaration is required by the Web Form Designer.
'Do not delete or move it.
Private designerPlaceholderDeclaration As System.Object
Private Sub Page_Init(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Init
'CODEGEN: This method call is required by the Web Form Designer
'Do not modify it using the code editor.
InitializeComponent()
End Sub
#End Region
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim x As New AnjaniSession.anjaniSession
Response.Write("session through hardy session result = " & x.hardysession("ram") & "<br> normal session after session.abandon <br> result = " & Session("r"))
If Not Page.IsPostBack Then
x.abandon()
Response.Write("<br> After anjani session.abandon <br>")
Response.Write("session through hardy session result = " & x.hardysession("ram") & "<br> normal session after session.abandon <br> result = " & Session("r"))
End If
End Sub
End Class


Other 1 submission(s) by this author

 


Report Bad Submission
Use this form to tell us if this entry should be deleted (i.e contains no code, is a virus, etc.).
This submission should be removed because:

Your Vote

What do you think of this code (in the Intermediate category)?
(The code with your highest vote will win this month's coding contest!)
Excellent  Good  Average  Below Average  Poor (See voting log ...)
 

Other User Comments
6/19/2007 1:37:47 AMHunter Beanland

There is no source code of the component. Your link only includes a dll. Planet Source Code is for source code, not dlls. Please post the code. I am interested to see if you have implemented full type checking and handling.
(If this comment was disrespectful, please report it.)

 

Add Your Feedback
Your feedback will be posted below and an email sent to the author. Please remember that the author was kind enough to share this with you, so any criticisms must be stated politely, or they will be deleted. (For feedback not related to this particular code, please click here instead.)
 

To post feedback, first please login.