找不到字段名称

时间:2015-05-06 08:26:35

标签: vba ms-access access-vba ms-access-2007

Install-Package Caliburn.Micro -Version 2.0.2

我收到错误消息PM> Install-Package Caliburn.Micro -Version 2.0.2 Attempting to resolve dependency 'Caliburn.Micro.Core (= 2.0.2)'. Installing 'Caliburn.Micro.Core 2.0.2'. Successfully installed 'Caliburn.Micro.Core 2.0.2'. Installing 'Caliburn.Micro 2.0.2'. Successfully installed 'Caliburn.Micro 2.0.2'. Adding 'Caliburn.Micro.Core 2.0.2' to WpfApplication1. Successfully added 'Caliburn.Micro.Core 2.0.2' to WpfApplication1. Adding 'Caliburn.Micro 2.0.2' to WpfApplication1. Successfully added 'Caliburn.Micro 2.0.2' to WpfApplication1.

但字段名称存在于我的表单中。
请帮助。

2 个答案:

答案 0 :(得分:2)

在VBA中添加表单控件的正确语法是:

Forms![YourFormName]![YourControlName]

仅当名称包含空格时才需要括号。

Forms("YourFormName").Controls("YourControlName")

答案 1 :(得分:0)

我改变了

strlbl = "Me.lblWarehouse" & i
strlblV = "Me.lblWarehouse" & i 

到:

strlbl = "lblWarehouse" & i
strlblV = "lblWarehouse" & i 

并且工作正常