Solved

MS Access Global Variables, Timeouts, and Security

Posted on 2014-10-08
5
311 Views
Last Modified: 2014-10-14
I have an application that I am building that has a low level requirement for security. I am planning on having a user table that stores login IDs, passwords, and security information about what objects they can access and what they cannot.

Upon successfully logging in, I was going to store their USERID in a global variable to be available throughout the application.

If I do this, can the application timeout such that the Global Variable loses it's value?
If so, what is the timeout period?
Any finally, is there a better way to store this info as they navigate and use the application?

Thanks!
0
Comment
Question by:GenesisTech
5 Comments
 
LVL 65

Expert Comment

by:Jim Horn
ID: 40369604
Regarding the Global Variables portion of this question eyeballeth thy article on Table Based Access Variables, which will demonstrate a wompload of options on how to pull this off.
0
 
LVL 75

Accepted Solution

by:
DatabaseMX (Joe Anderson - Access MVP) earned 500 total points
ID: 40369605
Yes ... there is a better way that Global Variables ... just for starters >> TempVars

Short tutorial on TempVars by Access MVP Juan Soto

http://blogs.office.com/b/microsoft-access/archive/2010/09/27/power-tip-maximize-the-user-of-tempvars-in-access-2007-and-2010.aspx

And TempVars can be called from a query ... which is pretty cool ... and they do not get reset if an error occurs, etc.

The application is not going to 'time out' all by itself. That would be under your control as a developer.

mx
0
 
LVL 57
ID: 40370335
You other option is to open a hidden form at start up and store items in unbound controls.

Jim.
0
 
LVL 34

Expert Comment

by:PatHartman
ID: 40370747
In most cases I use the hidden form technique suggested by Jim D because when I am testing, I can leave the form visible and watch all the variables or even change them manually.  I have also used the table based technique suggested by Jim H.  The table based method is excellent for when you need to retain values between sessions.  I do it a little differently though.  I keep the table in the BE rather than the FE.  That means that all users share the same physical table and so I need to include their ID along with the variableID.  When you keep the table in the FE, it is specific to a single user so you don't need to worry about the userID but you do loose the settings when the FE is replaced and users don't like that.
0
 

Author Closing Comment

by:GenesisTech
ID: 40381031
Awesome. I was not aware of TempVars. Excellent Solution - Thanks!
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I originally created this report in Crystal Reports 2008 where there is an option to underlay sections. I initially came across the problem in Access Reports where I was unable to run my border lines down through the entire page as I was using the P…
Overview: This article:       (a) explains one principle method to cross-reference invoice items in Quickbooks®       (b) explores the reasons one might need to cross-reference invoice items       (c) provides a sample process for creating a M…
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.
In Microsoft Access, learn different ways of passing a string value within a string argument. Also learn what a “Type Mis-match” error is about.

919 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now