Hi Ed:
No, you can't delay the loading of Normal: it's part of the application
You are going to a bad place trying to rely on this reverse alphabetic load
order: it's just not stable, it WILL end in tears
Use J.E.'s macro to load the templates in the order that you need them
May I ask, for your personal machine, why you would NEED more than one? And
why would it not be Normal template?
That's the purpose of Normal template -- to get code loaded for your
particular and specific use. Since each template/add-in you load has an
overhead (maybe a hundred k, depending what's in it) you would normally
reduce the number you load to the minimum.
So the only reason you would have multiple add-ins is because you intend to
load and unload them as you need them. If you're intending to load them and
leave them, you would normally choose to have only one. Then you don't have
to consider this problem at all.
In the meantime, I would strongly suggest that you consider migrating your
function to AppleScript. AppleScript is the way forward in Word on the Mac.
VBA currently does not access the full functionality of Mac Word, and that
is going to get progressively worse with each new release until eventually,
VBA will not be a realistic solution on the Mac.
In the next version of Mac Word, I suspect that we will find that "a lot" of
the every-day functionality will be inaccessible to VBA. Word is going to
get major changes: VBA is a dead technology that is not going to get
updated, because it can't be secured sufficiently. On the PC, the new
functionality is all moving to VB.NET, which can be locked down.
The only thing VB.NET has in common with VBA is the name: it's a completely
different platform, and there's little likelihood that it will come to the
Mac platform: we don't need it, we have AppleScript.
Hope this helps
Cheers
Hi John,
No, I didn't know of Karen Walker's article of Word Templates. I was
searching the MS Communities for messages relating to template load order
when I ran across one post that mentioned reverse alphabetic. Thanks for the
link, it helps a lot to read others results.
I have done my own testing on Mac Word 10.1.6 on OSX 10.2.8 and indeed see
the reverse alphabetic load order --and-- the fact that Normal is always
loaded first. I also found, that if Normal has a reference to a global
template in it (here I mean a template file in the Startup folder), it will
automatically try to load that template as well.
I my particular case I needed my global templates to load in a specific
order because of the tasks each does. I had to name them, keeping in mind the
reverse alphabetic order, such that my global templates were loaded in the
order I needed them.
Is it true then that you can't delay the loading of Normal until after all
global templates have been loaded in Word?
Ed
John McGhie [MVP - Word and Word Macinto said:
Hi Ed:
I assume you have been reading the article by Karen Walker, Senior Developer
with Payne Consulting Group, Inc. at
http://www.payneconsulting.com/pub_books/articles/pdf/HowWordLooksforandLoad
sTemplates.pdf
Karen appears to be writing about Word 2003. She determined her results by
experimentation. I am afraid that you need to do the same. There is no
guarantee that Mac Word does the same thing
I don't think Karen mentioned it, but Normal is always loaded "First",
although it is the "last" place Word will look for macros.
Our sad experience is that it is simply not safe to "assume" that Word will
load add-ins in any given order. You "may" be able to get the order stable
for a single machine in an unchanging environment. But I would recommend
that you do not rely on it. In a multi-user networked environment, forget
it: you have a better chance in the lottery
If you tell us what you are trying to do, we can be a lot more help.
Personally, I use Application.Run or Call or enumerate the add-ins to ensure
that it does not "matter" in which order Word loads things.
You can make things more stable by carefully controlling your Customisation
Context, but again, I do not bother.
Decide what you need and call it explicitly when you need it: it's the only
safe way.
Hope this helps
Hi,
I understand that if I have more than one template in the Word Startup
folder, that they are loaded in reverse alphabetical order (Z --> A). Is the
Normal template always loaded first by Word, before any global templates in
the Startup folder are loaded?
I'd like Normal to be loaded after the templates in the Startup folder are
loaded. How does one do that? More generally, can one specify to Word to
load
a set of templates in Startup and My Templates, together w/Normal, to be
loaded in a specific order ? ie. can one override the default reverse
alphabetic load sequence?
Thanks!
Ed
--
Please reply to the newsgroup to maintain the thread. Please do not email
me unless I ask you to.
John McGhie <
[email protected]>
Microsoft MVP, Word and Word for Macintosh. Consultant Technical Writer
Sydney, Australia +61 (0) 4 1209 1410
--
Please reply to the newsgroup to maintain the thread. Please do not email
me unless I ask you to.
John McGhie <
[email protected]>
Microsoft MVP, Word and Word for Macintosh. Consultant Technical Writer
Sydney, Australia +61 (0) 4 1209 1410