hi, whats wrong with my code????

N

Norbert Lünow

Hallo,

I want to step through all controls in a form

Private Sub Form_BeforeUpdate(Cancel As Integer)
Dim ctl As Control
Dim k As Integer
Dim ctlName As String

For k = 0 To Me.Controls.count - 1 ' access counts right
Set ctl = Me.Controls(k) 'the helptext under the
mouse-cursor shows "10"
ctlName = ctl. 'I can't set the name
here
Next k
End Sub

so, whats wrong???

Greetings, Norbert
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top