回复 10 楼 w360989426
你用这种方式解决问题了?我一般是这样解决的funtion canOption(catalog as string)
'指定目录对应的控件可以执行操作
dim a as control
for each a in me.controls
if a.name=catalog then
a.enabled=true '该功能按钮有效
exit function
endif
next
end function
function noOptionAll
'所有操作按钮不能操作(假设所有按钮名称前四个字符为menu)
dim a as control
for each a in me.controls
if left(a.name,4)="menu" then a.enabled=false
next
end function