Automation error library not registered 2147319779

`I currently use the following VBA to create my quarterly reports. 'Dim ppApp As PowerPoint.Application Dim ppSlide As PowerPoint.Slide Dim shp As Object Dim myTextBox As Object Dim PPTTit...

`I currently use the following VBA to create my quarterly reports.

'Dim ppApp As PowerPoint.Application   
 Dim ppSlide As PowerPoint.Slide
 Dim shp As Object
 Dim myTextBox As Object
 Dim PPTTitle As String
 Dim PPTFooter As String
 Dim i As Integer
 Dim q As Integer
 Dim ChrtstoCopy As Integer
 Dim TblstoCopy As Integer
 Dim Firstslide As Boolean
 Dim CurrentSite As String
 Dim shortDeptName As String
 Sub CopytoPPT(Lbox_Exp, Lbox_Lis, Lbox_Rec)

 'ACTIVATED BY: Userform2 Command Button
 'PURPOSE: Copy the printareas for slides 1-5 in picture format and then 
  paste to a PPT slide.

 'Identify the criteria for the PPT slides
  CurrentSite = UserForm2.SiteTbox.Value
  ChrtstoCopy = Slide1_Sht.Range("S19").Value - 1
  TblstoCopy = Slide5_Sht.Range("D5").Value
  Firstslide = True
  If UserForm2.CheckBox1 = True Then
  blinded = " (Blinded)"
  Else
  blinded = " (Unblinded)"
  End If

 shortDeptName = 
 TgtSht.Range("SaveFileName").Find(What:=CurrentSite).Offset(0, 1).Text
 fileNameString = TgtSht.Range("SaveFolder") & TgtSht.Range("SavePrefix") & 
  " - " & shortDeptName

  'Open PPT application and existing blank PPT template file
   Set ppApp = New PowerPoint.Application
   ppApp.Visible = True 

The VBA is used to paste my data into graphs presented in a power point. Recently my desktop got updated to a 64 bit and when I try to run my VBA to produce the power point I need it gives me the following error message.
Run-time error ‘-2147319779 (8002801d)’:
Automation error
Library not registered

I tried to further investigate what could possibly be causing this and I believe it may be related to the command «Set ppApp = New PowerPoint.Application».

When I try to just run the Macro for PasteImgtoPPT I get a
Run-time error ’91’:
Object variable or with block variable not set error.

I have been trying for weeks to fix this VBA but can’t seem to find the solution. Any help would be greatly appreciated!

  • Remove From My Forums
  • Вопрос

  • Hello all, I am working from Excel and want to send mails. I have referenced Microsoft Outlook 12.0 Object Library and Microsoft Outlook View Control . I have this error reading the first line of code.

    Dim OutlookApp as Outlook.Application

    Set OutlookApp = New Outlook.Application

    Need help thanks.


    Thanks to all that continue to serve as help HashMan

Ответы

  • Hi,

    The automation library registration error is typical Office installation error. In your case, Office of two versions are installed side by side. Please completely remove both from Control Panel, and install only one version that you requires.

    thanks.


    Forrest Guo | MSDN Community Support |
    Feedback to manager

    • Предложено в качестве ответа

      18 января 2013 г. 4:56

    • Помечено в качестве ответа
      Forrest Guo
      30 января 2013 г. 12:18

`В настоящее время я использую следующий VBA для создания квартальных отчетов.

'Dim ppApp As PowerPoint.Application   
 Dim ppSlide As PowerPoint.Slide
 Dim shp As Object
 Dim myTextBox As Object
 Dim PPTTitle As String
 Dim PPTFooter As String
 Dim i As Integer
 Dim q As Integer
 Dim ChrtstoCopy As Integer
 Dim TblstoCopy As Integer
 Dim Firstslide As Boolean
 Dim CurrentSite As String
 Dim shortDeptName As String
 Sub CopytoPPT(Lbox_Exp, Lbox_Lis, Lbox_Rec)

 'ACTIVATED BY: Userform2 Command Button
 'PURPOSE: Copy the printareas for slides 1-5 in picture format and then 
  paste to a PPT slide.

 'Identify the criteria for the PPT slides
  CurrentSite = UserForm2.SiteTbox.Value
  ChrtstoCopy = Slide1_Sht.Range("S19").Value - 1
  TblstoCopy = Slide5_Sht.Range("D5").Value
  Firstslide = True
  If UserForm2.CheckBox1 = True Then
  blinded = " (Blinded)"
  Else
  blinded = " (Unblinded)"
  End If

 shortDeptName = 
 TgtSht.Range("SaveFileName").Find(What:=CurrentSite).Offset(0, 1).Text
 fileNameString = TgtSht.Range("SaveFolder") & TgtSht.Range("SavePrefix") & 
  " - " & shortDeptName

  'Open PPT application and existing blank PPT template file
   Set ppApp = New PowerPoint.Application
   ppApp.Visible = True 

VBA используется для вставки моих данных в графики, представленные в Power Point. Недавно мой рабочий стол обновился до 64-разрядной версии, и когда я пытаюсь запустить свой VBA для получения необходимой мне точки питания, появляется следующее сообщение об ошибке. Ошибка времени выполнения «-2147319779 (8002801d)»: библиотека ошибок автоматизации не зарегистрирована

Я попытался дополнительно изучить, что могло быть причиной этого, и я считаю, что это может быть связано с командой «Set ppApp = New PowerPoint.Application».

Когда я пытаюсь просто запустить макрос для PasteImgtoPPT, я получаю сообщение об ошибке времени выполнения «91»: объектная переменная или ошибка с неустановленной блочной переменной.

Я неделями пытался исправить этот VBA, но, похоже, не нашел решения. Любая помощь будет принята с благодарностью!

1 ответ

Лучший ответ

Скорее всего, у вас нет ссылки на Microsoft Powerpoint в проекте, поэтому попытка объявить переменную, которая ссылается на powerpoint, потерпит неудачу (ваш проект не знает, что это такое).

Чтобы рассказать об этом вашему проекту (сделать ссылку), перейдите в Инструменты >> Ссылки и найдите его в списке:

enter image description here

Проверьте это и нажмите «ОК», затем попробуйте снова запустить VBA.

Вы также можете подумать о позднем связывании переменных PowerPoint, чтобы не ссылаться на них:

 Dim ppApp As Object  
 Dim ppSlide As Object
 Set PPApp = CreateObject("PowerPoint.Application")
 Set ppSlide = PPApp.Slide

CreateObject загружает ссылку на Powerpoint.Application во время выполнения.


1

JNevill
30 Июл 2018 в 19:17

  • Remove From My Forums

 locked

Excel 2010 VBA Macro Error — Library Not Registered

  • Question

  • We are using Office 2010 and Lync 2013.

    When trying to run the macro below, an error appears Run-time error ‘-2147319779 (8002801d)’: Automation error Library not registered.

    I have tried registering Excel, Word, and have tried deleting the Registry value for 2013. Nothing works. The only way I have gotten around it is by installing all of Office 2013. Is there any other change I can make for the user besides installing
    2013? Company standard is 2010 and management would prefer to keep users on this standard if possible.

    Sub shovedatatoMSWord()

    Dim wApp As Word.Application

    Dim wDoc As Word.Document

    Set wApp = CreateObject(«Word.Application»)

    wApp.Visible = True

    Set wDoc = wApp.Documents.Add

    wDoc.Content.InsertAfter Range(«A1»)

    End Sub

    • Moved by

      Tuesday, August 11, 2015 1:34 AM

Same problem here.
I think he uninstalled the Microsoft Office 2007 primary interop assemblies. After I uninstalled that, it worked again…

John.Austi wrote:

Dear Jialiang,winword.exe /r did not solve the problem.
16-Aug-07

Dear Jialiang,

winword.exe /r did not solve the problem.

Our program is compiled with a reference to the word 2000 dll as we still
have some users with Word 2000, however it works on other machines with 2003
(including mine).

The customer uninstalled «some program with 2007 in the name» and the
problem is now fixed!

Thanks for your assistance — I wish I knew what he uninstalled!


John Austin

:

Previous Posts In This Thread:

‘Library not registered’ error creating word.application
On a customers site, one computer with Word 2003 raises an error when our
application tries to create a Word.Application object. The VB6 line ‘ Set wd
= New Word.Application’
gives error -2147319779 Automation error Library not registered.

I saw an article that used regtlib to register the Msword.olb library, but
the regtlib.exe file did not exist in the user’s Windows folder. I tried
copying regtlib from my PC to his and re-registering Msword.olb — it said
that it was registered, but still the application fails.

My customer has now told me that Office 2007 was previously installed on the
PC and was removed and replaced with Office 2003. Has this a bearing on the
problem?

How can I diagnose and fix this issue?

Many thanks,

John Austin

RE: ‘Library not registered’ error creating word.application
Hello John,

From your post, my understanding on this issue is: you get the error:
2147319779 when the vb6 code runs to Set wd = New Word.Application. Office
2007 was once installed on the pc, then it was removed and replaced with
office 2003. If I’m off base, please feel free to let me know.

As we know, the error 2147319779 means ‘Library not registered’ according
to the KB article http://support.microsoft.com/kb/186063. Because the pc
was once installed with Office 2007, my suggestion is:
Tools->References). Has it referenced to the correct Word library:
Microsoft Word 11.0 Object Library? (11.0 is the current version of Word in
your computer)
Word 2003 dlls. You may go to Start: Run, and type:
c:path to your word 2003Winword.exe /r
This will cause Word to rewrite all of its registry keys with their default
values. When you’ve done that, double check the Word reference in the vb
project, then try the code again.

If both the suggestions cannot help to resolve the problem, would you tell
me the type of your customer’s site? Is it a Retail Solution Site?

Sincerely,
Jialiang Ge ([email protected], remove ‘online.’)
Microsoft Online Community Support

==================================================
For MSDN subscribers whose posts are left unanswered, please check this
document: http://blogs.msdn.com/msdnts/pages/postingAlias.aspx

Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications. If you are using Outlook Express/Windows Mail, please make sure
you clear the check box «Tools/Options/Read: Get 300 headers at a time» to
see your reply promptly.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx.
==================================================
This posting is provided «AS IS» with no warranties, and confers no rights.

Dear Jialiang,winword.exe /r did not solve the problem.
Dear Jialiang,

winword.exe /r did not solve the problem.

Our program is compiled with a reference to the word 2000 dll as we still
have some users with Word 2000, however it works on other machines with 2003
(including mine).

The customer uninstalled «some program with 2007 in the name» and the
problem is now fixed!

Thanks for your assistance — I wish I knew what he uninstalled!


John Austin

:

Hey ThereI had the same problem.
Hey There

I had the same problem. And when I removed ???Microsoft Office 2007 Primary
Interop Assemblies??? via the Control panel the error disappeared. Thanks for
pointing me in the right direction.

Steffen

:

RE: ‘Library not registered’ error creating word.application
It worked for me too :)
Thanks for finding a solution.

ZeXr0

:

Re: ‘Library not registered’ error creating word.application
wrote:

Many thanks for this it helped me too

Peter

Submitted via EggHeadCafe — Software Developer Portal of Choice
NoSQL, MongoDB Install, Lotus Notes, and CouchDB
http://www.eggheadcafe.com/tutorial…725-3e1c27969596/nosql-mongodb-install-l.aspx

Error Message

While installing or uninstalling ArcGIS Desktop, the following error is received:

«RegCat
Run-time error ‘-2147319779 (8002901d)’: Automation error
Library not registered.»

Or when launching ArcMap, the following error is received:

«Startup
Automation Error
The specified module could not be found.»

Cause

This error occurs when the Window Script engine is missing from the computer.

Solution or Workaround

Install the Windows Script engine. The link to the Windows Script engine download is listed below in Related Information.

    Related Information

    • Windows Script 5.6 for Windows XP and Windows 2000
    • Windows Script 5.7 for Windows XP

    Last Published: 5/5/2016

    Article ID: 000009855


    A few weeks back I had a problem on a clients site, our application which interacts with Word files, was falling over when trying to create a Word object. This was not a problem with our coding as it has been working fine for many years and this problem was specific to a couple of workstations.

    The error given was «-2147319779 Automation error Library not registered».

    This error does happen if parts of Office become corrupt and sometimes if the normal.dot template file is corrupted, so tried all the usual fixes to correct these problems. None of these seemed to work and correct the fact that it could not create a Word object.

    On further investigation I had found that the client had decided to try out Office 2007 on the two workstations in questions, they later decided they did not like it that much, uninstalled and re-installed Office 2003.

    When Office 2007 is uninstalled, by default it leaves behind it’s Interop Assemblies. These must be removed separately, which the users had not done. Uninstalling ”Microsoft Office 2007 Primary Interop Assemblies” though the control panel -> add and remove programs, corrected the problem.

    Problem: error code «-2147319779 Automation error Library not registered» when trying to work with Word files or Excel from separate application.
    Cause: Installing Office 2007 and then removing it at later date replacing with previous version.
    Resolution: Uninstall ”Microsoft Office 2007 Primary Interop Assemblies”.
    Cause of Problem: Microsoft Office. 

    Paul B
    MCP

    Home →
    Troubleshooting →
    All Products: Startup →
    «Automation error: Library not registered»

    Applies to:
    All products

    When I try to launch the Palisade software, I get the error message

    Automation error: Library not registered

    or

    Method ‘~’ of object ‘~’ failed

    I’ve tried repairing the Palisade software, but that didn’t help.

    This appears to be due to an error in the System Registry entries for Excel, not Palisade. If you have Excel 2007 and you have the option to upgrade to 2010, several users reported that upgrading fixed their problem.

    This error is especially likely if you have multiple versions of Excel and uninstall one of them. In that case, one or more keys in the System Registry are left behind pointing to the version of Excel that no longer exists.  To remove these «orphan» keys, please follow the procedure in Removing Outdated References to Office from the System Registry.

    There’s a special case, as of 2017-11-30. When you install Skype for Business 2016, it installs this System Registry key:

    HKEY_CLASSES_ROOTTypeLib{2DF8D04C-5BFA-101B-BDE5-00AA0044DE52}2.8

    That key refers to Office 2016, and if you don’t have Office 2016 that’s a problem, not just for @RISK but for other programs such as Microsoft Word. If your Palisade software was working, and it stops working when you install Skype for Business 2016, and you don’t have Office 2016 installed, remove that key.

    See also: «Method ‘~’ of object ‘~’ failed» (at Startup)

    Additional keywords: Error 2147319779, -2147319779

    last edited: 2018-02-12

    Понравилась статья? Поделить с друзьями:
  1. Automation error 2147417848
  2. Automatic registration failed at join phase exit code unknown hresult error code 0x801c001d
  3. Automake error no makefile am found for any configure output
  4. Automake error configure ac is required
  5. B0022 0d шевроле каптива ошибка