How to Click Cell to add an X to a cell and click again to remove it

klitton7

New Member
Joined
Jul 24, 2024
Messages
18
Office Version
  1. 2019
Platform
  1. Windows
See attachment. We would like to be able to send the document to users who will click the box when the step is finished. If they need to remove the checkmark, they could click again. I would like a rather large "X" to be displayed in the box.
 

Attachments

  • CheckMarks.png
    CheckMarks.png
    47.8 KB · Views: 8

Excel Facts

Test for Multiple Conditions in IF?
Use AND(test, test, test, test) or OR(test, test, test, ...) as the logical_test argument of IF.
I'm assuming you're after a vba solution. Regardless, using checkboxes might be a better idea. AFAIK, the only 2 options you'd have vba event-wise is BeforeRightClick or Worksheet_SelectionChange. The latter would fire upon every cell click and while that won't necessarily be noticed, it may cause other vba subs or functions to run. That may be preventable. The right click would only fire on a mouse right button click, which would be OK as long as you'd never want the right click (context) menu for those cells. Here's how you might do it with right click:
VBA Code:
Private Sub Worksheet_BeforeRightClick(ByVal Target As Range, Cancel As Boolean)

Select Case Target.AddressLocal
    Case "$B$3"
        Target = "X"
        Target.Characters.Font.Size = 20
        Cancel = True
End Select
   
End Sub
EDIT - rather than repeat that x times I might try to think of a way that doesn't repeat the same basic code 5 or more times.
 
Upvote 0
Solution
Thanks for your response. I decided to convert the form to a pdf and add check boxes.
 
Upvote 0

Forum statistics

Threads
1,224,027
Messages
6,175,990
Members
452,693
Latest member
Dethpod1

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