Referencing Form Controls from a Module

  • Thread starter Thread starter Wembly
  • Start date Start date
W

Wembly

Hi,

Is it possible to write routine that accesses form
controls from a module function?

E.g. This code sits in the Module

Public Function ControlActions(Level, Action)
....
With Forms![formName]
Select Case Action
Case "Lock"
For Each Ctrl In .Controls
Ctrl.Tag = Level & "Lockable"
Ctrl.Locked = True
Next Ctrl
Case "Unlock"
...
 
Back
Top