Sub SwapSelectedCells() Dim tempValue As Variant Dim cellA As Range, cellB As Range 'Check if exactly two cells are selected If Selection.Count 2 Then MsgBox "Please select exactly two cells to swap.", vbInformation, "Selection Error" Exit Sub End If 'Assign the selected cells to their respective variables Set cellA = Selection(1) Set cellB = Selection(2) 'Store the value of cellA in a temporary..