MDI's

  • Thread starter Thread starter S4
  • Start date Start date
S4 said:
How can I preserve variables for a MDI session?


What is an MDI (Multiple Document Interface?) session? Which variables do
you want to preserve for which purpose?
 
I have a seach screen that calls a MDI Parent form that has several MDI
Child form options. Since more than one seach can be clicked on and
therefore more than one MDI Parent form can be open at one time, I need tp
keep all variables within each MDI Parent/Child session distict. What is
the best way to declare and keep track of each MDI session variables.

Thanks again,

Richard

--
Richard Grene


________________________________

This mailbox protected from junk email by MailFrontier Desktop
from MailFrontier, Inc. http://info.mailfrontier.com
 
Herfried,

This is what happens when people code for the web and then move to
applicatioins :) Session variables are a part of webpage programming as I
realized from Richard's second post

Richard,

The 'Session' variables go out of scope as soon as you close the instance of
that MDI form. While the form is instantiated you can access the 'Session'
variables this way provided the variable has been declared with Public Scope
(Use Public instead of Dim)

myForm.VariableName

Cheers
Cyril
 
If I declare the Public variable in a module, that variable would be
accessable from the MDI & Child forms. If I have more than 1 MDI Parent
open at the same time then the variables would be shared and that is BAD. I
need the variables in each MDI Parent/Child sessions distinct from each
other.

Thanks

--
Richard Grene

S4 Solutions, Inc,
1757 Merrick Avenue
Suite 204
Merrick, NY 11566
516-379-8630
516-379-8633 (fax)

________________________________

This mailbox protected from junk email by MailFrontier Desktop
from MailFrontier, Inc. http://info.mailfrontier.com
 
S4 said:
If I declare the Public variable in a module, that variable would be
accessable from the MDI & Child forms. If I have more than 1 MDI
Parent open at the same time then the variables would be shared and
that is BAD. I need the variables in each MDI Parent/Child sessions
distinct from each other.

How did you managed to have multiple MDI parent forms in one single
application?

You now see why Modules can be a bad thing. Declare the variables in the
MDI parent as they obviously belong to the MDI parent. Pass them to the
child Forms when necessary. Perhaps you will have to redesign something and
go the OOP way.


Armin
 
My app is a Client/Server Collections system is as follows:
1. The user logs in and gets a list of people to call. When they select a
person, I have a MDI parent open and the MDI parent has various MDI children
options.

2. While the first MDI Parent is open, the user has the option to bring up
another person, thereby opening another MDI Parent/Child forms.

The issue is, whats the best way to maintain the inegrity of variables
within each MDI session. Right now I use Public variables in a module and
that of course does not keep varaible distinct between MDI Parents.

Thanks
I

--
Richard Grene

S4 Solutions, Inc,

________________________________

This mailbox protected from junk email by MailFrontier Desktop
from MailFrontier, Inc. http://info.mailfrontier.com
 
S4 said:
My app is a Client/Server Collections system is as follows:
1. The user logs in and gets a list of people to call. When they
select a person, I have a MDI parent open and the MDI parent has
various MDI children options.

2. While the first MDI Parent is open, the user has the option to
bring up another person, thereby opening another MDI Parent/Child
forms.

Ok, did not even know this was possible.
The issue is, whats the best way to maintain the inegrity of
variables within each MDI session. Right now I use Public variables
in a module and that of course does not keep varaible distinct
between MDI Parents.


I still suggest to put them into the MDI parent.


Armin
 
Back
Top