Friday, April 11, 2008

Set VBProject Properties using VBA

Set the Project Name of VBA project programmatically

The ActiveVBProject property returns the project that is selected in the Project window or the project in which the components are selected. In the latter case, the project itself isn't necessarily selected. Whether or not the project is explicitly selected, there is always an active project. This name, description of the VB Project can be set as follows:

Sub Get_The_PRoject_Name()

Application.VBE.ActiveVBProject.name = "MyVBAProject"

Application.VBE.ActiveVBProject.Description = "This is My Personal VBA Project"

End Sub

1 comment:

  1. Anonymous1:06 PM

    Apparently, not in Outlook VBA.

    ReplyDelete

StumbleUpon
Share on Facebook
Related Posts Plugin for WordPress, Blogger...
Download Windows Live Toolbar and personalize your Web experience! Add custom buttons to get the information you care about most.