Problem with Radio Button's format control

darcyfournier

Board Regular
Joined
Nov 21, 2017
Messages
54
I am creating an employee evaluation template (a sample is below)

Column A is the category

Column B, C D, E and F will be ratings (unacceptable, below, meets, exceeds, outstanding) with radio button options.

Column E is the ratings total for whatever rating above is selected 1-5 because their are 5 options

In the the first category Attire- it works perfectly. No matter what I select, it places the right value in BOX E in that row. If I select Unacceptable, it puts a 1 there..if I selected Outstanding it puts a 5.

However- when doing the same thing for the next category in the row below (Qaulity of work), instead of putting a 1-5, it adds one and my values are now 6-10.

How do I get the options buttons to only be 1-5 for each row?


1575601743795.png
 

Attachments

  • 1575601570992.png
    1575601570992.png
    15.5 KB · Views: 7
Last edited:
If you want to stick with option buttons, then you will need to put them all in group boxes, with one group box per row.

Another option would be to use VBA & get the user to double-click a cell
 
Upvote 0

Excel Facts

Which Excel functions can ignore hidden rows?
The SUBTOTAL and AGGREGATE functions ignore hidden rows. AGGREGATE can also exclude error cells and more.
If you want to stick with option buttons, then you will need to put them all in group boxes, with one group box per row.

Another option would be to use VBA & get the user to double-click a cell
Understood...that would eliminate them from being connected. Got it.

How would I make an x appear when I click a cell (or a check mark)?
 
Upvote 0
Right click the sheet tab you want this to work on, select View Code & paste this into the window that opens up
VBA Code:
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean)
    If Not Intersect(Target, Range("B:F")) Is Nothing Then
        Cells(Target.Row, 2).Resize(, 5).ClearContents
        Target.Value = "X"
        Cells(Target.Row, 7) = Target.Column - 1
        Cancel = True
    End If
End Sub
Then double click in columns B to F
 
Upvote 0
Right click the sheet tab you want this to work on, select View Code & paste this into the window that opens up
VBA Code:
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean)
    If Not Intersect(Target, Range("B:F")) Is Nothing Then
        Cells(Target.Row, 2).Resize(, 5).ClearContents
        Target.Value = "X"
        Cells(Target.Row, 7) = Target.Column - 1
        Cancel = True
    End If
End Sub
Then double click in columns B to F


EXACTLY what I needed and it solved everything else too! THANK YOU!!!!!
 
Upvote 0
You're welcome & thanks for the feedback
 
Upvote 0
Right click the sheet tab you want this to work on, select View Code & paste this into the window that opens up
VBA Code:
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean)
    If Not Intersect(Target, Range("B:F")) Is Nothing Then
        Cells(Target.Row, 2).Resize(, 5).ClearContents
        Target.Value = "X"
        Cells(Target.Row, 7) = Target.Column - 1
        Cancel = True
    End If
End Sub
Then double click in columns B to F


One last thing...How would I make this a single click event and not double click?
 
Upvote 0
You could make it
VBA Code:
Private Sub Worksheet_BeforeRightClick(ByVal Target As Range, Cancel As Boolean)
event instead.
 
Upvote 0
I am encountering a problem with this Formula.

Some of the cells in the row, but not the cells where the range is at in the code, are merged. When I go to click on the range cells to put my X in, it tells me it cannot do that to a merged cell. Those cells where I am clicking are not merged, but there are other cells in the same ROW that are but they are not in the code range.

How do I get past this?
 

Attachments

  • 1575938263230.png
    1575938263230.png
    116.3 KB · Views: 3
Upvote 0
You're welcome & thanks for the feedback

I am encounting a problem.

The code worked perfect...and now I started to build my evaluation page. The code is to put an "X" when double clicking is currently set for a rang of of H:L

However, on rows in coluns A through H are merged cells. So now, when I go to click on cells in H through L, I am getting an error that this cannot be done in a merged cell (even thought no cells in H-L are merged).

How do I get around this?
 
Upvote 0
Glad to see you realized using a large number of Option buttons is not a good way to do things.
And using merged cells can cause a lot of problems when using Vba.
 
Upvote 0

Forum statistics

Threads
1,215,219
Messages
6,123,687
Members
449,117
Latest member
Aaagu

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top