473,394 Members | 1,829 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,394 software developers and data experts.

Global Variables and Terminal Services

I have an Access XP app running over TS with Windows 2000 Server.
There are 5 sites (each with 3 or 4 users) accessing the data file, and each
has its own front end mde on the server. The mde's open exclusively.

When a user at site 'A' prints a report or opens a form, it is called using
something like:
DoCmd.Openreport rptname, , , "PropNum = " & gblPropNum
Where the PropNum is a unique ID (byte) for the property for which that site
has access, and gblPropNum is a global variable (byte) which is set once for
each site when the app is opened.

An intermittent problem (twice in 3 months) is occurring where data from a
second site finds its way into a report or a form for the first site.

Is it possible that the global variable could be the cause?
Has anyone else seen anything similar?

--
Bob Darlington
Brisbane
Nov 13 '05 #1
6 1737
Personnally, I don't use global variables anymore Too unstable anyway. I
suggest that you use an hidden form with controls used as the variable.
"Bob Darlington" <bo*@dpcmanAX.com.au> wrote in message
news:40***********************@news.optusnet.com.a u...
I have an Access XP app running over TS with Windows 2000 Server.
There are 5 sites (each with 3 or 4 users) accessing the data file, and each has its own front end mde on the server. The mde's open exclusively.

When a user at site 'A' prints a report or opens a form, it is called using something like:
DoCmd.Openreport rptname, , , "PropNum = " & gblPropNum
Where the PropNum is a unique ID (byte) for the property for which that site has access, and gblPropNum is a global variable (byte) which is set once for each site when the app is opened.

An intermittent problem (twice in 3 months) is occurring where data from a
second site finds its way into a report or a form for the first site.

Is it possible that the global variable could be the cause?
Has anyone else seen anything similar?

--
Bob Darlington
Brisbane

Nov 13 '05 #2
In what context do you mean 'unstable'?
I've been using them, albiet in a limited way, for many years and not found
any instability.
My problem now is within the TS environment.
Are you saying that the stability changes when used in TS?

--
Bob Darlington
Brisbane
"Saintor" <sa******@REMOVETHIShotmail.com> wrote in message
news:uh********************@weber.videotron.net...
Personnally, I don't use global variables anymore Too unstable anyway. I suggest that you use an hidden form with controls used as the variable.
"Bob Darlington" <bo*@dpcmanAX.com.au> wrote in message
news:40***********************@news.optusnet.com.a u...
I have an Access XP app running over TS with Windows 2000 Server.
There are 5 sites (each with 3 or 4 users) accessing the data file, and

each
has its own front end mde on the server. The mde's open exclusively.

When a user at site 'A' prints a report or opens a form, it is called

using
something like:
DoCmd.Openreport rptname, , , "PropNum = " & gblPropNum
Where the PropNum is a unique ID (byte) for the property for which that

site
has access, and gblPropNum is a global variable (byte) which is set once

for
each site when the app is opened.

An intermittent problem (twice in 3 months) is occurring where data from a second site finds its way into a report or a form for the first site.

Is it possible that the global variable could be the cause?
Has anyone else seen anything similar?

--
Bob Darlington
Brisbane


Nov 13 '05 #3
"Bob Darlington" <bo*@dpcmanAX.com.au> wrote in message
news:40***********************@news.optusnet.com.a u...
In what context do you mean 'unstable'?
I've been using them, albiet in a limited way, for many years and not found any instability.
My problem now is within the TS environment.
Are you saying that the stability changes when used in TS?


The only "instability" that I'm aware of is that an unhandled runtime error
can cause global variables to lose their setting. This doesn't happen in
an MDE though.

I agree with you as I have used them for years with no issues. Most of
mine are set and then used within a short time interval. I might be a
little more worried using a global variable that needs to retain its value
for the entire session, but again, I've never encountered any problems.
--
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com
Nov 13 '05 #4
"Bob Darlington" <bo*@dpcmanAX.com.au> wrote in message news:<40***********************@news.optusnet.com. au>...
In what context do you mean 'unstable'?
I've been using them, albiet in a limited way, for many years and not found
any instability.
My problem now is within the TS environment.
Are you saying that the stability changes when used in TS?

--
Bob Darlington
Brisbane
"Saintor" <sa******@REMOVETHIShotmail.com> wrote in message
news:uh********************@weber.videotron.net...
Personnally, I don't use global variables anymore Too unstable anyway.

I
suggest that you use an hidden form with controls used as the variable.
"Bob Darlington" <bo*@dpcmanAX.com.au> wrote in message
news:40***********************@news.optusnet.com.a u...
I have an Access XP app running over TS with Windows 2000 Server.
There are 5 sites (each with 3 or 4 users) accessing the data file, and each has its own front end mde on the server. The mde's open exclusively.

When a user at site 'A' prints a report or opens a form, it is called using something like:
DoCmd.Openreport rptname, , , "PropNum = " & gblPropNum
Where the PropNum is a unique ID (byte) for the property for which that site has access, and gblPropNum is a global variable (byte) which is set once for each site when the app is opened.

An intermittent problem (twice in 3 months) is occurring where data from a second site finds its way into a report or a form for the first site.

Is it possible that the global variable could be the cause?
Has anyone else seen anything similar?

--
Bob Darlington
Brisbane


I think I remember reading recently in this NG about global variables,
such as strings, losing their values when a run-time error gets caught
by the 'On Error' mechanism. I have seen other situations where the
global value just gets lost mysteriously. You probably don't rely on
On Error as much as he does so you don't detect any 'instability.'
Also, whenever if I use a global string I try to keep the time between
setting it and using it to a minimum.

James A. Fortune
Nov 13 '05 #5
Rick and James,
Thanks for the input.
As you say, as long as all procedures have error handlers, there shouldn't
be a problem with globals.
But I guess my question should be:
"Does anything change when used within a TS session?"

--
Bob Darlington
Brisbane
"Bob Darlington" <bo*@dpcmanAX.com.au> wrote in message
news:40***********************@news.optusnet.com.a u...
In what context do you mean 'unstable'?
I've been using them, albiet in a limited way, for many years and not found any instability.
My problem now is within the TS environment.
Are you saying that the stability changes when used in TS?

--
Bob Darlington
Brisbane
"Saintor" <sa******@REMOVETHIShotmail.com> wrote in message
news:uh********************@weber.videotron.net...
Personnally, I don't use global variables anymore Too unstable anyway.
I
suggest that you use an hidden form with controls used as the variable.
"Bob Darlington" <bo*@dpcmanAX.com.au> wrote in message
news:40***********************@news.optusnet.com.a u...
I have an Access XP app running over TS with Windows 2000 Server.
There are 5 sites (each with 3 or 4 users) accessing the data file,
and each
has its own front end mde on the server. The mde's open exclusively.

When a user at site 'A' prints a report or opens a form, it is called using
something like:
DoCmd.Openreport rptname, , , "PropNum = " & gblPropNum
Where the PropNum is a unique ID (byte) for the property for which
that site
has access, and gblPropNum is a global variable (byte) which is set
once for
each site when the app is opened.

An intermittent problem (twice in 3 months) is occurring where data

from a second site finds its way into a report or a form for the first site.

Is it possible that the global variable could be the cause?
Has anyone else seen anything similar?

--
Bob Darlington
Brisbane



Nov 13 '05 #6
"Bob Darlington" <bo*@dpcmanAX.com.au> wrote in message news:<40***********************@news.optusnet.com. au>...
Rick and James,
Thanks for the input.
As you say, as long as all procedures have error handlers, there shouldn't
be a problem with globals.
Let me clarify. The run-time error that you don't see because it's
caught by the error handler causes problems with global variables --
sometimes.
But I guess my question should be:
"Does anything change when used within a TS session?"


I don't know if anything changes within a TS session. My guess is
that the problem will happen just as often because the changes that TS
brings is largely moving more of the responsibility to the server side
rather than waving a magic wand that heals Access' problems.

James A. Fortune
Nov 13 '05 #7

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

Similar topics

5
by: Sara_S | last post by:
I am ready to move my ASP web site onto a remote host. The problem is that when I use Terminal Services to see the host machine, the error does not show up. (I was told that debugging info is only...
3
by: Josh Schmidt | last post by:
How can one set the terminal services profile and home directory path in AD using VB.NET? I can set the usual profile paths, but terminal services properties are not supported with ADSI. Any...
33
by: DFS | last post by:
An application I wrote has been deployed on Citrix, and the Citrix admin tells me all users run the same .mde file. There aren't a lot of concurrent users, but even 2 could be cause for concern. ...
5
by: TPoise! | last post by:
Using: .NET 1.1, Visual Studio 2003, C#, Microsoft Windows 2000 Server (SP4 and all latest windows updates), Terminal Server running in application mode. I have a C# application that I've...
0
by: Brian Young | last post by:
My department is responsible for creating custom internal applications for many of our departments. Our strategy has always been to develop our applications as ActiveX controls (VB6) that get...
8
by: OHM | last post by:
Hi peoples, I dont know where to place this question, so as I know you guys are all resourceful experts, I thought I would try here. I am writing some code which will be run usingh remote...
2
by: Vinu | last post by:
Hi, I am facing one problem related to global variables in .so file. When ever I access the variable the application is crashing I have a class called services. class services { services(){...
3
by: shawn | last post by:
In the past I have had SQL and Terminal server on the same PC. With SQL and Windows 2003 Terminal server, you can not have them on the same PC. How can I make this work with SQL and Terminal and...
0
by: Gary Herron | last post by:
Jacob Davis wrote: Yuck, YUCK, YUCK! You are breaking *so* many good-programming-practices, I hardly know where to start. First off: A python global is not what you think. There are *no*...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

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.