MSProject2007:如何使用VBA以编程方式在GLOBAL.MPT中设置引用

问题描述:

您好

有没有人知道如何
以编程方式
在GLOBAL.MPT中设置引用。

Does anyone know how to programmatically set the reference in GLOBAL.MPT.

我创建了一个工具栏和一些从代码项目复制到的模块GLOBAL.MPT。但无法在global.mpt中添加引用。

I have created a toolbar and some modules which are copied from code project to global.mpt. But unable to add a reference in global.mpt.

我尝试了一些选项但没有运气

i tried some options but no luck

Application.VBE.ActiveVBProject.References.AddFromguid&quot ; {00020813-0000-0000-C000-000000000046}",1,2,


以上代码是在当前项目中添加引用而不是global.mpt

Application.VBE.ActiveVBProject.References.AddFromguid "{00020813-0000-0000-C000-000000000046}", 1, 2

above code is adding a reference in current project instead of global.mpt

请建议......

MOhit

VBE.vbprojects(1)引用全局

VBE.vbprojects(1) refers to the global

HTH