vba - 从另一个窗体调用控件获取错误:未找到方法或数据成员
问题描述
我在编译我的项目时遇到错误 Method or data member not found。按钮控件“btnViewUpdateRefresh”以其他形式存在。
Private Sub UserForm_Terminate()
Dim oSection As Word.Section
Dim oRange As Word.Range
Dim var
If Documents("PART V1.0.docm").ProtectionType <> wdNoProtection Then
Documents("PART V1.0.docm").Unprotect "1234"
Else
End If
ThisDocument.Activate
ThisDocument.StoryRanges(wdMainTextStory).Delete
MainWindow.Show
Call MainWindow.btnViewUpdateRefresh_Click --> error points in here.
If Documents("PART V1.0.docm").ProtectionType <> wdNoProtection Then
Else
Documents("PART V1.0.docm").Protect wdAllowOnlyFormFields, True, "1234"
End If
结束子
解决方案
推荐阅读
- html - html 到 cshtml - 无法解释的页面移动
- xamarin - 如何在 xamarin 表单的顶部选项卡式页面上添加搜索选项卡?
- python - 第二高分
- sql - 将 JSON 数组批量插入到 SQL Server 表中,以列分隔
- azure-devops - Azure Devops 构建只为 webapi 服务创建 bin、web.config 和 global.asax
- wordpress - wordpress网站标识中的双徽标?
- php - 如何根据我在弹性搜索中给定的输入值进行动态弹性搜索查询
- angular - 我可以根据表单结果在 Angular 6 中创建全局数组吗?
- php - 使用空名称解析 json 对象
- json - 在c#中将json转换为列表