+ Reply to Thread
Results 1 to 3 of 3

CheckBox check marks save

  1. #1
    p. panter
    Guest

    CheckBox check marks save

    I had genrated a "UserForm" with some "CheckBox". Now I would like to save
    the document with some check mark's (true, on) but always when I open again
    the document there are no check marks visible.

    Here is the code that I use:

    Private Sub CheckBox1_Click()
    Sheets("test").Activate
    If CheckBox1.Value = True Then
    Range("12:12, 18:18, 33:33").EntireRow.Hidden = False
    Else
    Range("12:12, 18:18, 33:33").EntireRow.Hidden = True
    End If
    End Sub





    Thenks in advance!



  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258
    Hello P. panter,

    Open the VB editor, open your Form and make sure the property window is dsiplayed (press F4). Select the check box on your UserForm and set the VALUE property to TRUE. Repeat for each check box you want to come up checked. Then save the changes.

    Sincerely,
    Leith Ross

  3. #3
    Registered User
    Join Date
    02-07-2006
    Posts
    26

    Using names

    If you want to keep the checkbox value each time you change it, you could define names to store the values and hide them.

    Names.Add Name:="Storevalue1", RefersTo:=value

    Next time you open the form, read values from the name with:

    checkbox1.value = [Storevalue1]

    Regards.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1