Home > Domino Tips > Spam and Security > Log Out Users When There Is No Activity On A Database
Domino Tips:
EMAIL THIS
 TIPS & NEWSLETTERS TOPICS 

SPAM AND SECURITY

Log Out Users When There Is No Activity On A Database


Manbir Bhullar
03.26.1999
Rating: -3.50- (out of 5)


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


You have seen in secure web sites that if there is no activity on the form for
certain time you are logged out.Similiar results can be acheived by using the
following code below.

How to Log out user's when there is no activity on a database?

Code

----GLOBAL DECLARATIONS ------

Dim elapsedTime As Integer
Dim elapsedTimer As NotesTimer
%INCLUDE "lsconst.lss"

------POSTOPEN FORM EVENT ------
Sub Postopen(Source As Notesuidocument)
Dim session As New NotesSession
Set elapsedTimer = session.CreateTimer()
elapsedTimer.Interval = 1
elapsedTimer.Comment = "Elapsed time since opening document"
elapsedTime = 0
On Event Alarm From elapsedTimer Call elapsedTimerHandler

End Sub


-----ELAPSEDTIME SUBROUTINE-------


Sub elapsedTimerHandler(Source As NotesTimer)
Dim workspace As New NotesUIWorkspace
Dim uidoc As NotesUIDocument
Set uidoc = workspace.CurrentDocument

elapsedTime = elapsedTime + 1
Print elapsedtime

If elapsedtime=4 Then

If uidoc.EditMode Then
Call uidoc.FieldSetText( "SaveOptions", "0" )
uidoc.close
Messagebox ("Temp-1")
Else
uidoc.close

twoLiner = |This message is on two lines-2|
Messagebox twoLiner, MB_OK, "Demo"
End If



End If

End Sub


Rate this Tip
To rate tips, you must be a member of SearchDomino.com.
Register now to start rating these tips. Log in if you are already a member.


Submit a Tip




Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   



RELATED CONTENT
Spam and Security
Securely connect Lotus Domino servers on different domains
Protect Lotus Notes from malicious code with the Domino ECL
How to correct Lotus Notes public key mismatches in four easy steps
A recipe for secure IM success
Telecommuter security kit
Spear phishing: Don't be a target
FAQ: Lotus Notes Domino password issues
Security awareness training: How to educate employees about spyware
Seven tips to strengthen your Domino e-mail security
Admin2005 preview: Tips, techniques, and a look at Notes/Domino Rel. 7

RELATED RESOURCES
2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
Search Bitpipe.com for the latest white papers and business webcasts
Whatis.com, the online computer dictionary

DISCLAIMER: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.



Domino & Lotus Notes Security Solutions: Authentication, Antispam, Encryption and Antivirus
HomeTopicsITKnowledge ExchangeTipsAsk the ExpertsMultimediaWhite PapersDomino IT Downloads
About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
SEARCH 
TechTarget provides technology professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective purchase decisions and managing their organizations' technology projects - with its network of technology-specific websites, events and online magazines.

TechTarget Corporate Web Site  |  Media Kits  |  Site Map




All Rights Reserved, Copyright 1999 - 2009, TechTarget | Read our Privacy Policy
  TechTarget - The IT Media ROI Experts