malik641
06-04-2006, 11:46 AM
Hey Guys :hi:
Can someone explain to me why I get an error when trying to show an instance of outlook from excel? I get an "Object doesn't support this property or method" error in this code (bolded where the error is):
Sub test1()
Dim objOL As New Outlook.Application
objOL.Visible = True
Set objOL = Nothing
End Sub
I can get it to work like this:
Sub test1()
Dim objOL As Variant
objOL = Shell("Outlook.exe", vbMaximizedFocus)
End Sub
Why won't it work the first way? I have the reference set in the VBE...:dunno
Can someone explain to me why I get an error when trying to show an instance of outlook from excel? I get an "Object doesn't support this property or method" error in this code (bolded where the error is):
Sub test1()
Dim objOL As New Outlook.Application
objOL.Visible = True
Set objOL = Nothing
End Sub
I can get it to work like this:
Sub test1()
Dim objOL As Variant
objOL = Shell("Outlook.exe", vbMaximizedFocus)
End Sub
Why won't it work the first way? I have the reference set in the VBE...:dunno