473,324 Members | 2,257 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,324 software developers and data experts.

Public (Global) variables

I capture the userid via a Login form and I need to use this userid for
other forms as well. How and where can I declare this variable
"strLoginID" such that its value can be used throughout the
application.

Regards,

Ninad.

Nov 13 '05 #1
4 1364
You should declare it in the 'General' section of a module. You
probably have one module containing your utility functions etc. You can
use the same.

HTH

Sunil Korah

Nov 13 '05 #2
Ack! Don't build your own security system. There's a perfectly good one
built in to access. When the person logs in, you'll be able to get
their login with the built in function CurrentUser().

Jeremy

Ninad wrote:
I capture the userid via a Login form and I need to use this userid for other forms as well. How and where can I declare this variable
"strLoginID" such that its value can be used throughout the
application.

Regards,

Ninad.


Nov 13 '05 #3

Ninad wrote:
Thanks for pointing towards a good direction. Is there any reference
material on the web where I can learn how to use it. I am not familiar with Access security system and will need a lead. TIA.

Ninad.


MS has a white paper on it. Check their website.

Nov 13 '05 #4
Thanks for pointing towards a good direction. Is there any reference
material on the web where I can learn how to use it. I am not familiar
with Access security system and will need a lead. TIA.

Ninad.

Nov 13 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

21
by: Anthony England | last post by:
Everyone knows that global variables get re-set in an mdb when an un-handled error is encountered, but it seems that this also happens when the variable is defined as private at form-level. So...
3
by: Mrs. Conni Drejer | last post by:
Please help anyone: I have made a DLL (for DBCommunication) in which I have defined some public static variables/fields in a public class. This because I want these variables to be shared in all...
8
by: Floris van Haaster | last post by:
Hi All! I have a question, i have a web application and I store some member information in a variable i declared in a module like: Public some_info_variable as string in module1.vb But...
2
by: vvenk | last post by:
Hello: I have defined public variables in Global.asax.vb that are initialized in the application_start event. How do I reference these variables in other ASP forms? For example, if my...
27
by: thomasp | last post by:
Variables that I would like to make available to all forms and modules in my program, where should I declare them? At the momment I just created a module and have them all declared public there. ...
9
by: CDMAPoster | last post by:
About a year ago there was a thread about the use of global variables in A97: http://groups.google.com/group/comp.databases.ms-access/browse_frm/thread/fedc837a5aeb6157 Best Practices by Kang...
11
by: sirsnorklingtayo | last post by:
What is the Difference between Global and Public, Dim and Private variables? in Visual Basic 6.0. Because I am always using Public and Dim but using Global and Private is doing the same thing, is...
5
by: John | last post by:
Hi Is there a way to declare public functions that can be accessed in any aspx page? Can global variables be declared? Thanks Regards
4
by: RP | last post by:
I have a class file (Global.cs) containing following variable: Public Int32 TotalRecords=0 I have a Windows Form from where I am assigning a value to this value as below: private void...
11
by: Web Search Store | last post by:
Hello, I set up a web page with 2 user controls. In classic asp, the first one did all the declarations, and the second one used the values, and could reset it. In ASP.Net so far I can't...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.