VBA code not working in 9.3.1

559
4
09-27-2010 11:31 AM
JohnCarpenter
New Contributor
Hi,

I wrote and saved some VBA code in a 9.3 ArcInfo .mxd document, which doesn't work in 9.3.1. The 'Macros' menu is disabled in the 'Tools' drop-down list and all of the icons in my toolbar are missing.

Is there something I need to install/enable to get 9.3.1 to recognize my code? I now have an ArcEditor license.

TIA
0 Kudos
4 Replies
JohnCarpenter
New Contributor
0 Kudos
JohnCarpenter
New Contributor
I don't have the installation discs (Arc 9.3.1 was installed by our IT manager), but I can access VBA 6.5 through Excel so I assume it's on my computer.

Does anyone know of a work-around that would allow Arc access to VBA 6.5 w/out using the discs?
0 Kudos
HeribertoMantilla_Santamaría
New Contributor
Hi.

If you can try open the Regedit and check out if VBA is enabled.


To re-enable VBA in the registry:

Navigate to HKEY_LOCAL_MACHINE\SOFTWARE\ESRI\ArcMap\Settings, double-click the PreloadVBA variable and set the value data to 0 from 1.

If the PreloadVBA has a value of 0; VBA is not loaded (disabled) when ArcMap starts. If the PreloadVBA has a value of 1; VBA is loaded (enabled) when ArcMap starts.
0 Kudos
JohnCarpenter
New Contributor
Thanks for the suggestion.

The PreloadVBA value was already set to 1. I set it to 0 and then back to 1 again. Each time I restarted ArcMap but the Macros Toolbar was still disabled.

Any other ideas?
0 Kudos