Simple Word DLL crashing Delphi

Add-in Express™ Support Service
That's what is more important than anything else

Simple Word DLL crashing Delphi
Simple Word DLL crashing Delphi when registering Active-X 
Tim Hayes




Posts: 5
Joined: 2007-02-21
Hi,

Microsoft today upgraded my Windows 10 Professional to latest Version 1809.

Straight after when using Word, my Add-in Task Pane caused a problem and it was disabled by Word. I use Office 365 Home.

I downloaded and installed the latest Add-in Express for VCL.

Now Delphi XE10 Seattle can build my program OK, but when I try to register the Active-X server, Delphi gives me an hourglass and then crashes out.

Help, please. Am I missing something? I am building a feature-rich desktop application and have been including a Word plug-in to enable integration during document editing.

Many thanks.

Regards

Tim Hayes
Posted 27 Aug, 2019 12:08:30 Top
Andrei Smolin


Add-in Express team


Posts: 18825
Joined: 2006-05-11
Hello Tim,

Try to register it using regsvr32. Also, check if this is reproducible on a new empty Word add-in project.


Andrei Smolin
Add-in Express Team Leader
Posted 28 Aug, 2019 04:21:40 Top
Tim Hayes




Posts: 5
Joined: 2007-02-21
Hi Andrei,

I have re-installed the demo project and still have an issue registering.

I have run Delphi 10.0 Seattle as Administrator. I am using Office 365 Home (is this restricted somehow?)

I open MyFirstAddin.dll project, and compile / build OK.

I then execute RUN/ActiveX Server/Register and I am given the message "Failed to register ActiveX Server "... MyFirstAddin.dll".

I then open Task Manager and execute FILE/Run new task/regsvr32.exe "path to dll" and check administrator privileges, and I get a successful install. This works in Excel, but when I re-compile with ohaWord checked in the AddInModule, module is still not registered in Word.

Your assistance would be most appreciated.

Kind regards

Tim Hayes
Posted 19 Sep, 2019 14:43:59 Top
Andrei Smolin


Add-in Express team


Posts: 18825
Joined: 2006-05-11
Hello Tim,

Delphi contains an error that occurs when you register a 64 bit ActiveX. It may be causing the Delphi crash.

If you register an add-in for Excel, then change the project to support Word and rebuild, this doesn't change the registration: you need to re-register again.

As to your add-in, on File | Options | Add-ins, choose Manage: Disabled Items and click Go. If your add-in is listed, re-enable it.


Andrei Smolin
Add-in Express Team Leader
Posted 20 Sep, 2019 08:00:19 Top
Tim Hayes




Posts: 5
Joined: 2007-02-21
Hi Andrei,

Thanks for responding.

I did some further research last evening and it appears that MS Word (such as I have in Office 365) is changed to replace COM add-ins in favour of what appears to be a javascript/html approach. See:

https://docs.microsoft.com/en-us/office/dev/add-ins/overview/office-add-ins

My test simply does not get registered in Word even though I re-registered both with and without ohaWord.

The application I am building needs close integration with word processing and with regret I am looking to use the DevExpress RichText component which looks good.

Many thanks for your kind assistance.

Best regards

Tim Hayes
Posted 20 Sep, 2019 08:56:15 Top
Andrei Smolin


Add-in Express team


Posts: 18825
Joined: 2006-05-11
Hello Tim,

Tim Hayes writes:
MS Word (such as I have in Office 365) is changed to replace COM add-ins


This is not so! It is changed to *support* JS-based addins! COM Add-ins are still available on the desktop versions of Word.

If you register the add-in and you get "succeeded", then the add-in is okay; otherwise you need to debug the code registering your add-in. If the add-in is registered but Word doesn't load it, your add-in is either unchecked in the COM add-ins dialog or it is disabled. Did you try to re-enable the add-in as mentioned above?


Andrei Smolin
Add-in Express Team Leader
Posted 20 Sep, 2019 10:26:17 Top
Tim Hayes




Posts: 5
Joined: 2007-02-21
Hi Andrei,

With apologies, the add-in is now showing in Word, after restarting Delphi. Registration within Delphi is also working provided I have Administrator privileges.

Kind regards

Tim Hayes
Posted 20 Sep, 2019 11:51:11 Top
Andrei Smolin


Add-in Express team


Posts: 18825
Joined: 2006-05-11
Hello Tim,

No problem! Thank you for letting us know!


Andrei Smolin
Add-in Express Team Leader
Posted 23 Sep, 2019 04:38:07 Top