When I try to insert it, I constantly get the "Cannot insert object" error. It seems to be a known issue with former Excel versions, but I couldn't find any support for 2016.
Has anyone been able to make this work?
Here are screenshots:
This appears to be intentional behaviour from Excel 2013 onwards. From this article:
This issue occurs because some scriptable controls are made obsolete
in Office 2013 for security reasons. This is by design, and these
errors are expected.
There is a workaround posted in that article which involves editing the registry to make these controls work again.
(The KnowledgeBase article was originally linked from this Microsoft community thread from 2014)
Fix ActiveX Controls (such as the Web Browser) in Excel (Office 2013-16)
Navigate to
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\ClickToRun\REGISTRY\MACHINE\Software\Wow6432Node\Microsoft\Office\16.0\Common\COM Compatibility\{8856F961-340A-11D0-A96B-00C04FD705A2}]
"Compatibility Flags"=dword:00000000
Navigate to in order to find the GUID of the control you are trying to fix (I was needing to fix the Web Browser control thus opened its GUID).
reference
Open the desired GUID and set dword to 0 (vs. 1024 (400H))
Context of the solution:
-Win 10 version 1803 / 64bit os
-Excel O365 ClicktoRun version 1806 10228.20080 / 64bit
The registry is located at
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\ClickToRun\REGISTRY\MACHINE\Software\Microsoft\Office\16.0\Common\COM Compatibility\{8856F961-340A-11D0-A96B-00C04FD705A2}
And set the "Compatibility Flags" DWord to 0
Note: To reenable the blocking feature set Dword value back to "400"
Killbit option
This article also helped: Cannot insert certain scriptable ActiveX controls into Office 2013 documents
And this one: Security Settings for COM objects in Office
Here is the file path for me: Win 10 x64 Build 1803 (17134.407)
Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\16.0\Common\COM Compatibility\{25336920-03F9-11CF-8FD0-00AA00686F13}
Hopefully, that helps someone
"Here is the file path for me: Win 10 x64 Build 1803 (17134.407)
Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\16.0\Common\COM Compatibility{25336920-03F9-11CF-8FD0-00AA00686F13}"
You need to set the compatibility flags to 0 for all the DWord entries in this Key not just the one mentioned above - then it works
Related
Just now i realized that my Excel Version is missing some functions, e.g. =UNIQUE() or =XLOOKUP(). Also in the tab with the list of all functions these are not available. Other functions work fine though. Is there a way to install these functions manually?
I am using: Microsoft® Excel® 2016 MSO (Version 2112 Build 16.0.14729.20156) 64 Bit
I just tried to update, but it is already up-to-date.
[Sidenote: I am using the German Version, so I am actually missing the functions =EINDEUTIG() and =XVERWEIS() but either or - these functions are missing in my Excel]
Unless you're using Microsoft Office 365 compatible version of Excel, your only other chance might be to sign up with Office Insider, which gives you access to exclusive new content / features as a trial user (whilst unique, filter, let, sort, sortby etc. functionality has been out for some time, there may well be dependencies on this RE: new content). Thanks to Insider I had access to unique functionality long before the Office 365 build was officially launched (about a year before if I remember correctly).
You can do both this and see what version Excel you are on by opening Excel and selecting File -> Account:
The client I'm working for recently upgraded all laptops to Microsoft Surface running windows 10 (version 10.0.16299) and Office 2016:
Microsoft Excel 2016 MSO (16.0.9126.2295) 64-bit
Microsoft Office 365 ProPlus
I'm working on an Excel VBA application that was working fine under the old laptops, but has now started crashing Excel with the following error:
An unhandled win32 exception occurred in EXCEL.EXE [14756]
There are different dialog messages that appear as Excel crashes:
Microsoft Excel has stopped working
Windows Error Reporting has stopped working
Another forum post recommended checking the Windows Event Viewer to obtain log of Error crash report. This gave me the following details:
Faulting application name: EXCEL.EXE, version: 16.0.9126.2295, time stamp: 0x5bafc794
Faulting module name: MSCOMCTL.OCX, version: 0.0.0.0, time stamp: 0x5984a51c
Exception code: 0xc0000005
Fault offset: 0x0000000000021f8f
Faulting process ID: 0x42c8
Faulting application start time: 0x01d47124a3a41f4c
Faulting application path: C:\Program Files\Microsoft Office\Root\Office16\EXCEL.EXE
Faulting module path: C:\windows\system32\MSCOMCTL.OCX
Report ID: 74d9c093-61f0-4616-b20b-dc7f2acda9a5
Faulting package full name:
Faulting package-relative application ID:
I've been searching numerous forums for solutions using the information I've gathered and so far come up empty.
I've isolated the problem to a specific user action, clicking on a ListView control. This control was added to the application to replace the former Listbox control on a form in order to allow the font colour to be set to red where an item had been selected. Since moving to the Surface laptops, this ListView control appears to be causing a conflict which is causing Excel to crash. I can’t be any more sure than that. Disabling the ListView control and setting the application to use the ListBox control appears to have resolved the issue.
I hope this is helpful to others. If anyone can explain why Excel is actually crashing, I'd appreciate it as I only feel I have a workaround, rather than a fix.
I'm wondering if there is a conflict with 64 bit v 32 bit drivers/dll files. The VBA references being used are:
VBA References
Mark
Thanks to #jkpieterse and #Comintern for advice.
The reasons for the problem were identified as migrating to Excel 2016 64 bit while using 32 bit controls and VBA code.
In the end there were a number of changes we had to make to prevent Excel crashing.
1) Removing all code and object references to the ListView object.
2) Following guidelines in this Microsoft article for ensuring VBA compatibility with Office 2016 64 bit: https://learn.microsoft.com/en-us/office/client-developer/shared/compatibility-between-the-32-bit-and-64-bit-versions-of-office
3) We ultimately contacted Microsoft support who recommended that to avoid the issue where Excel crashes, that we install a new registry key in:
HKEY_CURRENT_USER\Software\Microsoft\Office\16.0\Excel\Options\
Name: ForceVBALoadFromSource
Type: DWORD
Value = 1
(See Knowledge base article: https://support.microsoft.com/en-gb/help/4011597/december-5-2017-update-for-excel-2013-kb4011597)
They explained that this is a fix Microsoft have rolled out to force Excel to compile VBA fully on 64 bit systems which prevents problems when 32 bit code partially compiles.
Obviously you should backup your registry and create a restore point before applying this fix (and check with your Tech department if you have one!)
Prior to the support call I'd narrowed down the point of the crash to when a particular form was called. Prior to this point the VBA code was running fine, an ADODB connection had been successfully made to a SQL Server database with data being returned. When the form was called the application crashed. If I loaded a different form, the application did not crash implying there were other controls or code causing a compile error or conflict.
Also, I identified that the application did not crash if the Visual Studio Editor window was already open. I was able to add a line of code to programmatically open the VBE window (plus some to resize it so it did not hide the form):
Application.VBE.MainWindow.Visible = True
With Application.VBE.MainWindow
.Width = 500
.Height = 500
End With
After adding this code, the application did not crash either.
The problem form was too complex to recreate without a significant cost in development. fortunately the Microsoft fix has resolved the problem.
I recently had a similar issue of crashing when a sub-routine is called from an add-in. The code worked fine when manually debugged. We are using Excel 2016, 32 bit version. I figured out the issue was related to an uncompiled code in the add-in. After recompiling all the code using Debug -> Compile VBAProj from VBA editor, the error disappeared.
I'm using Excel 2016 to access a DDE server (Rockwell Software's RSLinx Classic.) The DDE server is working correctly/can be accessed from other applications. The problem is trying to access it from Excel.
This is what is in my cell: =RSLinx|PS9TOPIC1!'N7:0'
The PS9TPIC1 topic is set up (and works) in RSLinx. RSLinx is up and running. But I get:
Remote data not accessible... Start application RSLINX.EXE?
Clicking Yes gets:
Cannot run 'RSLINX.EXE'. The program or one of its components is missing or corrupted
The program runs fine. I have ensured that RSLinx.exe is on the PATH (Double-checked the PATH for the running Excel using Task Manager.) It doesn't matter whether I have RSLinx running before starting Excel or have Excel try to launch it.
No, the option to "Ignore other applications that use Dynamic Data Exchange" is not checked for this document.
I tried running both RSLinx and Excel as "Administrator" with the same result.
Bringing up the help for data connections shows this:
Note: In an earlier version of Excel, you might have used Dynamic Data Exchange (DDE) in combination with the Step-by-Step Mail Merge Wizard in Word. Excel no longer supports DDE. If you'd like us to consider this feature for the next version of Excel, drop us a comment in the Excel Suggestion Box.
Try using an older Excel license.
I had the same problem, i already solved it. Just go to your project in the kepserver, open properties, and make sure enable the DDE conection to your server... Just that in my case. Good luck..
enter image description here
I want to create a onenote book which I then share with a load of students. Using a cool little tool MS have produced, it will create sections for each student which they can access so they can READ my bits and EDIT their own but NOT see each others - I can read and edit all. Fab.
But their pages are blank. I want to be able to hit a button/macro/script/whatever to copy a select page from my section in to each of the other sections. Without using VS preferably.
Any ideas?
This tool that OneNote just released should make it doable, if you use the Win32 version of OneNote:
https://blogs.office.com/2016/03/08/introducing-the-class-notebook-add-in-for-onenote-designed-and-built-with-teachers/
I want to find whether ms office is installed and version of it...
how can i do it ?
Microsoft Office Version Detector
How does it work?
The code is based on an outdated Microsoft knowledge base article Q247985 (the code in the knowledge base article does not work for Office 2003 or 2007). The code looks for a specific registry key which holds the version for each application (e.g. HKEY_CLASSES_ROOT/Excel.Application/CurVer for Excel) which contains the version encoded in a string ("Excel.Application.11" on my computer). The internal Microsoft version number (i.e. the "11" at the end of "Excel.Application.11" ) is then mapped to the external "marketing" name, that you will be more familiar with (e.g. the internal version "11" is more commonly known as "Office 2003").
Since you've tagged it as visual C++, I'm assuming you want to do it in C++.
One way is to parse through the following registry key
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall
For e.g.
Enumerate this key and find out if the value displayname contains Microsoft Office Excel MUI (English) 2007
You may also find the version number in other values like version, versionmajor, verisonminor
FYI you can use this registry key to find out almost any software which 'installs' on your system.
This is only for 32 bit installation though. For 64-bit installation, you'll need to find a similar tree structure inside registry node WOW6432Node.