View Single Post
 
Old 05-13-2019, 01:10 PM
Steve Kunkel Steve Kunkel is offline Windows 10 Office 2016
Advanced Beginner
 
Join Date: May 2019
Location: Seattle area
Posts: 81
Steve Kunkel is on a distinguished road
Default

Quote:
Originally Posted by gmaxey View Post
It didn't work because it was out of order:

Code:
Private Sub Document_New()
  With formMain
    .optSch1.Caption = "School One"
    .optSch2.Caption = "School Two"
    .optSch3.Caption = "School Three"
    .Show
  End With
End Sub
...
Actually... As I look at my first post at the top, I see that I didn't have With and End With.

Code:
private Sub Document_New()
   formMain.Controls(optSchl).Caption = "One High" 
   formMain.Controls(optSch2).Caption = "School Two" 
   formMain.Controls(optSch3).Caption = "Sch Three"
   formMain.Show 
End Sub
Perhaps this was causing the odd behavior of only one caption being populated (?) Like maybe lines 2, 3, and 4 were over-writing each other?
Reply With Quote