Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Frame1.SpecialEffect = fmSpecialEffectFlat
Frame1.Caption = vbNullString
Private Sub Frame1_Click()
Dim OfTheControls As Control
Beep
Debug.Print Frame1.Controls.Count
For Each OfTheControls In Frame1.Controls
Debug.Print OfTheControls.Name
'Debug.Print OfTheControls.Tag 'Optional technique
Next
End Sub
Dim ctrl As Control
For Each ctrl In UserForm1.Controls
If TypeName(ctrl) = "ComboBox" Then
With ctrl
.Clear
.AddItem "Oil"
.AddItem "Gas"
End With
End If
Next ctrl
Dim ctrl As Control
For Each ctrl In UserForm1.Controls
If TypeName(ctrl) = "TextBox" Then
With ctrl
.Enabled = False
.Locked = True
End With
End If
Next ctrl
Sub WorksheetControls()
Dim oleobj As OLEObject
Dim msg As String
For Each oleobj In ActiveSheet.OLEObjects
msg = msg & "Object Name: " & oleobj.Name & _
vbTab & "Type: " & TypeName(oleobj.Object) & _
vbTab & "Index: " & oleobj.Index & _
vbTab & "Left: " & oleobj.Left & _
vbTab & "Top: " & oleobj.Top & vbCrLf
Next oleobj
MsgBox msg, vbOKOnly, "Sheet " & ActiveSheet.Name & " Object Information"
End Sub