Get outlook to start a userform in excel.

S

s_smith_iet

I have a outlook code to open an excel spread sheet when outlook is
opened.
What I need now is for it to start a user form in that spread sheet.

Please see code

Thanks

Private Sub Application_Startup()
Folder = "\\Mascarolinabdc\puball\Stuff ~ Stephen\"
FName = "NPI email macro.xls"
On Error Resume Next

Set excelbook = GetObject(Folder & FName)

With excelbook
.Application.Visible = True
.Parent.Windows(FName).Visible = True


End With

End Sub
 

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