when we HAVE TO pass a parameter in openargs, then that is not an
universal
solution.
Well, my point here is that model forms can be opened by wizards, by the
simple fact of creating a custom menu bar, and many many other ways.
If your question was to find out if a form is model, then I would accept the
need for a solution that tells you this fact, since NO code is needed to
open a form in model.
However, with acDialog, since CODE MUST be used, then it seems to me the
simple solution to add something the open args, and be done with this
problem.
I just don't understand your huge effort in trying to find a universal
solution, but then you come back and state the problem is that you as a
developer is just too lazy to modify the calling code? This does not make a
lot of sense!! You are willing to make such huge and un-necessary effort to
figure out if a you as a developer was too lazy to pass a value in the open
args?
You are wasting valuing time for no perceived benefit.
What are you going to do in the case that the developer forgets to include
the acDialog in the calling code? How will you know that the developer
actually wanted the form to be acDioalog, or in fact it was a mistake?
My suggestion was based on the fact that it takes a GOOD BIT of effort to
open a form in acDialog, and if the application needs special handling in
this case, then I can't imagine the effort to include a parameters via
openargs would not be a solution here?
When you find anything not right, please tell me.
Yes, my point is the cost of your solution is more then the time and
resources spent to obtain the solution. Further, what happens if the
developer forgets to include the acDialog parameter? You main point to me
what that the developer might forget to include the OpenArgs parms, and I am
throwing this right back at you, and stating that the developer might forget
to include the acDialog parm.
This whole thing revolves around the fact that it takes a conscious effort
to open a form in acDialog. If it did not take any effort on the developers
side, then I am 100% in agreement with you on the need for a universal
solution.
So, my point here is that your solution gains little, or nothing in terms of
saved time and effort.
The fact is you can always do a global search on code for the acDialog
parameter, and in a number of minutes find ALL occurrences of this. (but, if
the developer forgets to include the acDialog..then you got the same problem
as when you use openargs).
Perhaps you are willing to re-fund the wasted time to your employer or
client who is paying for this?