Published Forms

S

Snake_Plisken

A couple of months ago I asked for assistance in creating a custom form for
our IT Dept. The form has been created and works perfectly. Thank you for
your help. However, I need to place a shortcut in everyone's toolbar, within
Outlook, for ease of access. The form is in the Organizatonal Forms Library.
I know users can access the form simply by opening the Organizational Forms
Library and choosing it. But of course, there are users that can't follow
simple instructions. So that is the reason for placing the shortcut in the
toolbar. I have included the Macro that we are trying to use to accomplish
this. But for some reason it will not access the Forms Library, only
pre-determined folders. Could someone help me with this code and get it to
point to the correct path where the form is stored. Thanks for any
suggestions.
Here is the Macro:

Sub RunMyForm()
Dim myOlApp As Application
Dim myNameSpace As NameSpace
Dim myFolder As MAPIFolder
Dim myItems As Items
Dim myItem As Object

Set myOlApp = CreateObject("Outlook.Application")
Set myNameSpace = myOlApp.GetNamespace("MAPI")
Set myFolder = _
myNameSpace.GetDefaultFolder(olFolderNotes)
Set myItems = myFolder.Items
Set myItem = myItems.Add("IPM.Note.IT Work Request")
myItem.Display

Set myOlApp = Nothing
Set myNameSpace = Nothing
Set myFolder = Nothing
Set myItems = Nothing
Set myItem = Nothing
End Sub

I changed the 4th "Set" line to read:
myNameSpace.GetDefaultFolder(OrganizationalFormsLibrary)
The form is entitled "IT Work Request".

Again, Thanks for any help.
 

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