Applying my macro to a range of cells...

Solved/Closed
lorihohen Posts 3 Registration date Tuesday December 31, 2013 Status Member Last seen January 2, 2014 - Dec 31, 2013 at 06:17 PM
 Blocked Profile - Jan 3, 2014 at 08:56 AM
I found this macro and it works perfectly....inserts an "x" on a single mouse click into cells, but I only want it active on a certain range of cells. How do I change the macro to make it functionally only on c4 thru s20?

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If UCase(Target.Value) = "X" Then
Target.Value = ""
Else
Target.Value = "X"
End If
End Sub

3 responses

Blocked Profile
Dec 31, 2013 at 06:32 PM
Wow, what a scope!

*Define on what conditions the count will increment.
Do you wish to have another X added to an already building column of "x's"?

0
lorihohen Posts 3 Registration date Tuesday December 31, 2013 Status Member Last seen January 2, 2014
Jan 1, 2014 at 10:37 PM
No. This worksheet was designed for a simple purpose. I work with adults with disabilities and created a work/chore chart that will be available to them on an interactive whiteboard (just want them to tap the board and have an "x" appear in the spreadsheet to indicate their job choice for the day). As you can see by my profession, I'm not computer genius, but I found this cool macro that works great for my purposes. The only problem is, if they "click" by accident on the wrong cell, an x will appear where I don't want an x. How can amend the macro to make it only work of the cells that are "touchable"?
0