Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Selection change code with merged cells
Happy new year everyone.
I have an issue with the code below and wondered if there was a way to get round the problem. The issue is that R11:S11 and R12:S12 are merged cells. With single cells, the code toggles between a tick (Wingdings character 252) and blank when each cell is selected. With merged cells nothing happens. Is there a way to enable the code when the cells are merged? Private Sub Worksheet_SelectionChange(ByVal Target As Range) '----- ENABLE TICKS IN RELEVANT BOXES ----- Application.EnableEvents = False On Error GoTo sub_exit With Worksheets("Sheet1") Set rTick = Worksheets("Sheet1").Range("R11:S12") If Not Intersect(Target, rTick) Is Nothing Then With Target If .Value = Chr(252) Then .Value = "" Else .Value = Chr(252) .Font.Name = "Wingdings" End If End With End If End With sub_exit: Application.EnableEvents = True End Sub |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Probklem with code, when merged cells | Excel Programming | |||
Autofit Merged cell Code is changing the format of my merged cells | Excel Discussion (Misc queries) | |||
Problem with code for merged cells | Excel Programming | |||
changing merged cells from code | Excel Programming | |||
Fine-tuning selection change event for merged cells & wrap text | Excel Programming |