Results 1 to 10 of 10

Writing option button data to specific cell in a table

Threaded View

teacher_rob Writing option button data to... 11-11-2011, 10:14 AM
Steffen Thomsen Re: Writing option button... 11-11-2011, 10:42 AM
teacher_rob Re: Writing option button... 11-11-2011, 11:02 AM
Steffen Thomsen Re: Writing option button... 11-11-2011, 11:28 AM
teacher_rob Re: Writing option button... 11-11-2011, 11:40 AM
Steffen Thomsen Re: Writing option button... 11-11-2011, 01:00 PM
teacher_rob Re: Writing option button... 11-11-2011, 01:41 PM
teacher_rob Re: Writing option button... 11-11-2011, 01:43 PM
teacher_rob Re: Writing option button... 11-11-2011, 02:57 PM
teacher_rob Re: Writing option button... 11-11-2011, 03:08 PM
  1. #1
    Registered User
    Join Date
    11-08-2011
    Location
    bergen county, NJ
    MS-Off Ver
    Excel 2007
    Posts
    72

    Writing option button data to specific cell in a table

    Hi all, thanks again for all your help !

    I'm attempting to merge two bits of code I have recently figured out through this forum.
    I want to add data from an option button (choice of 9 buttons in one frame) to a specific cell in a table based on the user's combobox selections...

    this is the code i'm using to get the specific cell... SCORE would be chosen by the user in the frame with all the option buttons

    Dim gradesheet As Worksheet
    Dim where1 As Range, where2 As Range
    
    Set gradesheet = ThisWorkbook.Worksheets(ComboBox3.Value)
    Set where1 = gradesheet.Range("B:B").Find(what:=ComboBox1.Value)
    Set where2 = gradesheet.Range("1:1").Find(what:=ComboBox2.Value)
    
    gradesheet.Cells(where1.Row, where2.Column) = gradesheet.SCORE.value
    this is the code for the option buttons, where "F11" would be the cell determined by the above code

    If F1opt60.Value = True Then
         Range("F11").Value = 60
    
    ElseIf F1opt65.Value = True Then
         Range("F11").Value = 65
         
    ElseIf F1opt70.Value = True Then
        Range("F11").Value = 70
        
    ElseIf F1opt75.Value = True Then
        Range("F11").Value = 75
        
    ElseIf F1opt80.Value = True Then
        Range("F11").Value = 80
        
    ElseIf F1opt85.Value = True Then
        Range("F11").Value = 85
        
    ElseIf F1opt90.Value = True Then
       Range("F11").Value = 90
       
    ElseIf F1opt95.Value = True Then
      Range("F11").Value = 95
      
    ElseIf F1opt100.Value = True Then
        Range("F11").Value = 100
    End If
    End Sub
    i can't figure out how to nest this...

    any help would be sooo much appreciated !

    thanks!
    -rob
    Last edited by teacher_rob; 11-11-2011 at 03:09 PM.

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