|
-
Jan 16th, 2007, 10:11 AM
#1
Thread Starter
Fanatic Member
[RSLVD] createobject for outlook message error
ok I get an " ActiveX object cant create object" error 429
I know its because we have this new Cisco security agent.. that
is blocking it.. unless I move the security to low.. so my question is
how can I make it bypass this error and not crash... I tried to make
a on error goto CantOpenObject... but it doesnt do it.. it just errors
and crashes the program.. I want to make it tell them to change
the settings..(really I want Cisco to allow my program to do it, but
there is not Allow list in it, only deny and its not in the deny)..
so anyone know how I cant test if it will allow it and then display and
not crash ?
Last edited by kevin_sauerwald; Jan 16th, 2007 at 12:10 PM.
Reason: resolved
-
Jan 16th, 2007, 11:20 AM
#2
Re: createobject for outlook message error
If you are running Outlook in an Exchange server environment then you can use the Exchange servers management functionality to allow your control/app to run.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Jan 16th, 2007, 11:51 AM
#3
Thread Starter
Fanatic Member
Re: createobject for outlook message error
actually I was talking to a co-worker to seconds after I wrote this..
he was opening outlook another way.. he had it referenced at design time
not at runtime like I was.. seems Cisco doesnt care if you have it referenced
in at design time only run time... so I rekon I'll make it call it that way from
now on..
thanks though.. see if below makes sense to you
incase another search finds this post
old way ..no Reference added
VB Code:
Dim objFileSys As New FileSystemObject
If objFileSys.FileExists(dirDirectory.Path & "\" & filFiles.FileName) Then 'If exists then proceed
Set objOutlook = CreateObject("Outlook.Application")
Set objOutlookMsg = objOutlook.CreateItem(0)
new way .. needs Microsoft Outlook added as reference.
VB Code:
Dim oApp As New Outlook.Application
Dim oEmail As Outlook.MAPIFolder
Dim oNameSpace As Outlook.Namespace
Set oNameSpace = oApp.GetNamespace("MAPI")
Set oEmail = oNameSpace.GetDefaultFolder(olFolderInbox)
With oEmail.Items.Add(olMailItem)
-
Jan 16th, 2007, 11:55 AM
#4
Re: createobject for outlook message error
Ok, you are now doing Early Binding. The main thing to watch out for when used on other systems is that what ever Outlook version you reference on the system you are compiling this on is going to be required on any system that uses it and since Outlook only lets you have one version instaled it is a bit restrictive. This is where Late Binding really helps out (what you were doing earlier). It allows the code to bind to whatever Outlook version s installed.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Jan 16th, 2007, 12:10 PM
#5
Thread Starter
Fanatic Member
-
Jan 16th, 2007, 12:33 PM
#6
Thread Starter
Fanatic Member
Re: [RSLVD] createobject for outlook message error
ha.. foiled again.. not cisco gets blocks this call..
Set oNameSpace = oApp.GetNamespace("MAPI")
so I guess I need to find a way to have Cisco think its an ok program..
-
Jan 16th, 2007, 12:34 PM
#7
Re: [RSLVD] createobject for outlook message error
Do you also run an Exchange Server?
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|