Access 2013/2016不支持treeview控件,报错“User defined type not defined" [英] Access 2013/2016 does not support treeview control, giving error message "User defined type not defined"

查看:64
本文介绍了Access 2013/2016不支持treeview控件,报错“User defined type not defined"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个 VBA 项目,它可以完美地运行到 windows 7(32,64 位)和 office 2010.但是当我尝试在 office 2013 或 2016 上运行它时.它不加载树视图控件并在以下位置出现错误:

私有 SelectedNode 作为 MSComctlLib.node

我已经尝试过的事情是:

  1. 彻底关注这篇文章http://thesmileycoder.com/treeview-working-in-access2013/>

  2. 在 SYSTEM32 和 SYSWOW64 文件夹中多次重新注册 MSCOMCTL.OCX/MSCOMCT2.OCX.

任何帮助都是appriciated!

解决方案

感谢您说明您使用的是 Office 64 位.

你应该看到这个 文章

具体部分:

<块引用>

32 位版本的 Office 中包含的大部分内容都包含在 64 位版本的 Office 中.

以下是 64 位版本的 Office 中没有的一些内容.

ActiveX 控件库,ComCtl - 此库包含用于构建解决方案的 ActiveX 控件.它最常用于 Microsoft Access、Microsoft Excel 和 Microsoft Word.

SharePoint 列表控件 SharePoint 技术中的列表视图在 64 位版本的 Office 中不可用.

关注:

<块引用>

ActiveX 控件库,ComCtl - 使用这些控件的任何解决方案都不起作用.其中一些控件没有好的替代方案.

编辑这个 页面 2010更详细地说明:

<块引用>

Office 2010 中的本机 64 位进程无法加载 32 位二进制文​​件.这包括 MSComCtl 的常用控件(TabStrip、Toolbar、StatusBar、ProgressBar、TreeView、ListViews、ImageList、Slider、ImageComboBox)和 MSComCt2 的控件(Animation、UpDown、MonthView、DateTimePicker、FlatScrollBar).这些控件由以前版本的 Microsoft Office 安装,由 32 位 Office 2010 安装.当代码迁移到 64 位 Office 2010 时,必须为使用这些控件的现有 Microsoft Office VBA 解决方案找到替代方案.64 位Office 2010 不提供 64 位版本的通用控件.

I have a VBA project which runs perfectly upto windows 7 (both 32,64 bit) and upto office 2010. But when i try to run it on office 2013 or 2016. It does not load treeview control and gives error at:

Private SelectedNode As MSComctlLib.node

The things i have already tried are:

  1. Followed this post thoroughly http://thesmileycoder.com/treeview-working-in-access2013/

  2. Re-registered MSCOMCTL.OCX/MSCOMCT2.OCX several times on both SYSTEM32 and SYSWOW64 folders.

Any help is appriciated!

解决方案

Thanks for clarifying that you're using Office 64-bit.

You should see this article

Specifically the section:

Most things included in the 32-bit version of Office are included in the 64-bit version of Office.

The following are some things not in the 64-bit version of Office.

ActiveX controls library, ComCtl - This library contains ActiveX controls used to build solutions. It is most commonly used in Microsoft Access, Microsoft Excel, and Microsoft Word.

SharePoint List control The list view in SharePoint Technology isn’t available in 64-bit version of Office.

Followed by:

ActiveX controls library, ComCtl - Any solutions using these controls don’t work. No good alternatives are available for some of these controls.

EDIT And this page for 2010 spells it out in more detail:

Native 64-bit processes in Office 2010 cannot load 32-bit binaries. This includes the common controls of MSComCtl (TabStrip, Toolbar, StatusBar, ProgressBar, TreeView, ListViews, ImageList, Slider, ImageComboBox) and the controls of MSComCt2 (Animation, UpDown, MonthView, DateTimePicker, FlatScrollBar).These controls were installed by previous versions of Microsoft Office and are installed by 32-bit Office 2010. An alternative must be found for existing Microsoft Office VBA solutions that utilize these controls when the code is migrated to 64-bit Office 2010. 64-bit Office 2010 does not provide 64-bit versions of the Common Controls.

这篇关于Access 2013/2016不支持treeview控件,报错“User defined type not defined"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆