VisioLibMain never called from Visio 2003 - why?

W

Walter Quirtmair

Hi,
I have a VSL written in C++ that is recognized by Visio 2003 on startup by
the given Startup-Folder. When macro-security is set to "Middle", I even get
asked if to activate Macros, which I do.

Bu then the main entry function VisioLibMain of that VLS is never called and
Add-Ons are never regeistered to Visio. I have no clue why and even more
confusing is that this worked on a different machine.

What can I check or do? What reasons may cause this behavior?

Thank you for any hints,
Walter
 
B

bnk

Probably your VSL depends on another DLL that is missing on the
machine.

If your VSL uses MFC or ATL, ensure you have relevant DLLs installed on
target machine, or use static libraries.

BTW, there is a neat visual tool in VS (or SDK?) that can shows wich
DLLs are missing - "DEPENDS.EXE"
 
P

Paul Herber

Hi,
I have a VSL written in C++ that is recognized by Visio 2003 on startup by
the given Startup-Folder. When macro-security is set to "Middle", I even get
asked if to activate Macros, which I do.

Does setting the security to Low make any difference?
Bu then the main entry function VisioLibMain of that VLS is never called and
Add-Ons are never regeistered to Visio. I have no clue why and even more
confusing is that this worked on a different machine.

Are you sure that the VSL startup completes successfully? If an
unhandled exception occurs then you may the symptoms you describe.

If you have access to the source code and can rebuild it then it is
worth putting in a simple message dialog box at the end of the startup
to say that it has got there.
Also, add
try
code
catch

to trap any errors.
 
W

Walter Quirtmair

Thanks for your help. In fact my VSL was missing a DLL and DEPENDS.EXE
showed it.

But after extending the PATH variable to find this DLL Visio still doesn't
work with my VSL.

I used Filemon to monitor all file access when Visio starts and it correctly
locates and accesses my VSL. But that's all, the VSL still never gets
called.

Walter
 
W

Walter Quirtmair

Thank you all for your help.

I deinstalled Visio, cleaned up the registry of any Visio entries, rebooted,
reinstalled Visio, set macro security to Low and now everything works as
expected.

Walter
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top