hello all,

I use the following code to lock my textboxes:

vb Code:
  1. Public Sub Lockdown()
  2.     For Each tb In Me.Controls
  3.         If TypeOf tb Is TextBox Then
  4.             tb.Locked = True
  5.             tb.BackColor = &H80FF80
  6.         End If
  7.     Next
  8.    
  9.     For Each dt In Me.Controls
  10.         If TypeOf dt Is DTPicker Then
  11.             dt.Enabled = False
  12.         End If
  13.     Next
  14. End Sub

My problem is this: I have 3 frames in an array and only want 2 of the 3 frames textboxes to be locked.

I try different variations of the above code, but nothing works as of yet.

Thanks ahead of time.