

- #My microsoft word 15.0 error messages update#
- #My microsoft word 15.0 error messages registration#
- #My microsoft word 15.0 error messages code#
So now my declarations look like this : Dim oW As Object, _ Just using Late Binding seems to do the trick for me, so even if I'm curious about why, I'm just glad this work again!
#My microsoft word 15.0 error messages code#
The reference is pointing an existing file again,īut my code that was working yesterday is now erroring on : Set oW = VBA.GetObject(, "Word.Application") "C:\Program Files (x86)\Microsoft Office\Office15\excel.exe" /regserver "C:\Program Files (x86)\Microsoft Office\Office15\excel.exe" /r "C:\Program Files (x86)\Microsoft Office\Office15\winword.exe" /regserver

#My microsoft word 15.0 error messages registration#
I've tried to force the registration of both Excel and Word with : "C:\Program Files (x86)\Microsoft Office\Office15\winword.exe" /r

I just found the Policy value that were referenced for version 14 (I have 15, Office 2013), so I backed it up and delete it. I still check in the Windows Registry to be sure, but there is no reference to any other version! I only have one version of MS Office on my computer and it wasn't upgrading or anything. Test 4 : Windows Registry and other versions of Office I've then added the path C:\Program Files (x86)\Microsoft Office\Office15\ into PATH environment variable:Īfterwards, all commands work, but I still get the same error in VBA. I've tried "C:\Program Files (x86)\Microsoft Office\Office15\winword.exe" /r to force registration but it didn't change a thing. Winword.exe /automation, winword.exe, winword /automation and winword say 'winword.exe.' is not recognisedīut start winword and start winword /automation work smoothly. Test 3 : Start from cmd and add to PATH environment variableĪs Meaden suggested, I tried opening Word from command lines : I've repaired Office installation, but same issue on same lines. I rebooted again and this time the Path of the reference changed to C:\Program Files (x86)\Microsoft Office\Office15\MSWORD.OLB, so the reference seems to works but I've got the same error on the same lines.Īpparently regsvr32 onlt works for DLL and OCX, so the I couldn't manually add the reference. Is there another way to restore the library? Or to force loading it? I've reboot and checked and my hidden files are visibles, so I just don't know what to do!!! and 4.), the file's reference MSWORD.OLB has disappeared!!!! o_O Reopen the project, re-add the reference to the "Microsoft Word"īut in the mean time (between 1.Go to the folder of the file's reference and run regsvr32 MSWORD.OLB in the console.Remove the reference to the "Microsoft Word".(for me, C:\Program Files (x86)\Common Files\microsoft In VB project, see where the file for the reference "Microsoft Word".Test 1 : Manually add the reference to the library Set oDoc = oW.Documents.Open(FolderToScan & NewFile)įor Each aField In oDoc.Fields '<- 1st errorĮrr.Description = Automation error - Library not registered.Įrr.HelpFile = C:\PROGRA~2\COMMON~1\MICROS~1\VBA\VBA7.1\1036\VbLR6.chm Set oW = VBA.GetObject(, "Word.Application") ' vbNullString Set oW = VBA.CreateObject("Word.Application")Īnd yet the declarations of variables like oW As Word.Application don't seem to cause any issue. Set oW = VBA.GetObject(, "Word.Application") and
#My microsoft word 15.0 error messages update#
I'm using Word from Excel to open documents and update links in them.Īt first, Word was opening and opened the Documents, but I got the error on the line : For Each aField In oDoc.FieldsĪfter trying to simply uncheck, then re-check the "Microsoft Word" reference,
