Checkmark question.

J

James Silverton

Hello All!

In Access you can set up a "cell" so that a checkmark can appear on one
mouse click and disappear on another. Can this be done in Excel?

Thanks in advance!

--


James Silverton
Potomac, Maryland

Email, with obvious alterations:
not.jim.silverton.at.verizon.not
 
F

FSt1

hi
not to my knowledge.
you can format the cell to font marlett then use the lower case a key to add
a check to the cell. del key to remove it.

Regards
FSt1
 
T

T. Valko

You need an event macro to do it with a mouse click.

Select the sheet where you want this to happen.
Right click the sheet tab, select View Code
Copy/paste the code below into the window that opens.

Option Explicit
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Dim myHeight As Double
Application.EnableEvents = False
On Error GoTo sub_exit
If Not Intersect(Target, Range("A1:A100")) Is Nothing Then
With Target
If .Value = "a" Then
.Value = ""
Else
myHeight = .EntireRow.RowHeight
.Value = "a"
.Font.Name = "Marlett"
.EntireRow.RowHeight = myHeight
End If
End With
End If
sub_exit:
Application.EnableEvents = True
End Sub

Close the window to return to Excel

The range effected is A1:A100. Change to suit.
 
T

T. Valko

a checkmark can appear on one mouse click and disappear on another.

The suggestion I made doesn't work *exactly* like that. It works based on
*selecting* the cell. If the cell is empty and you select it then a
checkmark is entered. To remove the checkmark you'd have to select another
cell then reselct the cell with the checkmark for it to be removed. The
closest you can get to using just "one mouse click" would be a before double
click event macro. If the cell is empty a double click enters the checkmark
and then another double click removes it.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top