#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 60
Default Run-Time error 429

When my company bought new computers I have started getting this error

Run-time error 429
ActiveX component can't create object

I know it's probably a reference but for the life of me I can not seem to
find which one it is.

Any help would be appreciated

DWB
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 60
Default Run-Time error 429

This is my code attached to a button, it fails on this line
Set OutApp = CreateObject("Outlook.Application")

Sub Mail_Sheet_Outlook_Body()
' Don't forget to copy the function RangetoHTML in the module.
' Working in Office 2000-2007
Dim rng As Range
Dim OutApp As Object
Dim OutMail As Object
With Application
.EnableEvents = False
.ScreenUpdating = False
End With

Set rng = Nothing
Set rng = ActiveSheet.UsedRange
'You can also use a sheet name
'Set rng = Sheets("YourSheet").UsedRange

Set OutApp = CreateObject("Outlook.Application")
OutApp.Session.Logon
Set OutMail = OutApp.CreateItem(0)

On Error Resume Next
With OutMail
.Recipients.Add "ASPHALT H2S"
.CC = ""
.BCC = ""
.Subject = Range("E4")
.HTMLBody = RangetoHTML(rng)
.DISPLAY
End With
On Error GoTo 0

With Application
.EnableEvents = True
.ScreenUpdating = True
End With

Set OutMail = Nothing
Set OutApp = Nothing
End Sub

Any help would be appreciated

DWB


"tankerman" wrote:

When my company bought new computers I have started getting this error

Run-time error 429
ActiveX component can't create object

I know it's probably a reference but for the life of me I can not seem to
find which one it is.

Any help would be appreciated

DWB

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default Run-Time error 429

I'd guess that you don't have Outlook installed.

Did your company install that program, too?

ps. This is not a reference error.

The code uses late binding (Dim OutApp as Object) and doesn't need the
reference.

But your program can't find Outlook.

tankerman wrote:

This is my code attached to a button, it fails on this line
Set OutApp = CreateObject("Outlook.Application")

Sub Mail_Sheet_Outlook_Body()
' Don't forget to copy the function RangetoHTML in the module.
' Working in Office 2000-2007
Dim rng As Range
Dim OutApp As Object
Dim OutMail As Object
With Application
.EnableEvents = False
.ScreenUpdating = False
End With

Set rng = Nothing
Set rng = ActiveSheet.UsedRange
'You can also use a sheet name
'Set rng = Sheets("YourSheet").UsedRange

Set OutApp = CreateObject("Outlook.Application")
OutApp.Session.Logon
Set OutMail = OutApp.CreateItem(0)

On Error Resume Next
With OutMail
.Recipients.Add "ASPHALT H2S"
.CC = ""
.BCC = ""
.Subject = Range("E4")
.HTMLBody = RangetoHTML(rng)
.DISPLAY
End With
On Error GoTo 0

With Application
.EnableEvents = True
.ScreenUpdating = True
End With

Set OutMail = Nothing
Set OutApp = Nothing
End Sub

Any help would be appreciated

DWB

"tankerman" wrote:

When my company bought new computers I have started getting this error

Run-time error 429
ActiveX component can't create object

I know it's probably a reference but for the life of me I can not seem to
find which one it is.

Any help would be appreciated

DWB


--

Dave Peterson
  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 60
Default Run-Time error 429

I did a detect and repair and found out that Office 2003 did an install, I'm
guessing but I thinki out new computers came with Office 2000. After the
install when I started up OutLook it did a initial setting on startup (I
think it said initial setting anyway) and now it works fine.

Thanks Dave for your help
Tankerman

"Dave Peterson" wrote:

I'd guess that you don't have Outlook installed.

Did your company install that program, too?

ps. This is not a reference error.

The code uses late binding (Dim OutApp as Object) and doesn't need the
reference.

But your program can't find Outlook.

tankerman wrote:

This is my code attached to a button, it fails on this line
Set OutApp = CreateObject("Outlook.Application")

Sub Mail_Sheet_Outlook_Body()
' Don't forget to copy the function RangetoHTML in the module.
' Working in Office 2000-2007
Dim rng As Range
Dim OutApp As Object
Dim OutMail As Object
With Application
.EnableEvents = False
.ScreenUpdating = False
End With

Set rng = Nothing
Set rng = ActiveSheet.UsedRange
'You can also use a sheet name
'Set rng = Sheets("YourSheet").UsedRange

Set OutApp = CreateObject("Outlook.Application")
OutApp.Session.Logon
Set OutMail = OutApp.CreateItem(0)

On Error Resume Next
With OutMail
.Recipients.Add "ASPHALT H2S"
.CC = ""
.BCC = ""
.Subject = Range("E4")
.HTMLBody = RangetoHTML(rng)
.DISPLAY
End With
On Error GoTo 0

With Application
.EnableEvents = True
.ScreenUpdating = True
End With

Set OutMail = Nothing
Set OutApp = Nothing
End Sub

Any help would be appreciated

DWB

"tankerman" wrote:

When my company bought new computers I have started getting this error

Run-time error 429
ActiveX component can't create object

I know it's probably a reference but for the life of me I can not seem to
find which one it is.

Any help would be appreciated

DWB


--

Dave Peterson

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Visual Basic Error Run Time Error, Type Mismatch Meg Partridge Excel Discussion (Misc queries) 12 September 10th 08 06:10 PM
I tried to get around the problem of the pivot table field settingdefaulting to Count instead of Sum by running a macro of change the settingfrom Count to Sum. However, when I tried to run the Macro, I got error messageof run time error 1004, unable Enda80 Excel Discussion (Misc queries) 1 May 3rd 08 10:52 AM
Receiving run-time error only part of the time [email protected] Excel Discussion (Misc queries) 0 August 11th 07 12:01 AM
run-time error '91'-Close Button error ASCO IS Help Excel Discussion (Misc queries) 1 May 8th 06 04:25 PM
Run time error 1004, General ODBC error [email protected] New Users to Excel 0 September 19th 05 01:41 AM


All times are GMT +1. The time now is 10:02 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"