Add checkboxes from the forms toolbar, then assign each checkbox to this
macro
Sub CheckValues()
Dim oCheckbox As CheckBox
Dim iRow As Long
With ActiveSheet
Set oCheckbox = .CheckBoxes(Application.Caller)
If oCheckbox.Value = xlOn Then
iRow = oCheckbox.TopLeftCell.Row
If .Cells(iRow, "J").Value = .Cells(iRow, "M").Value Then
MsgBox "Same on row " & iRow
End If
End If
End With
End Sub
--
HTH
Bob Phillips
(remove nothere from the email address if mailing direct)
"nik_gujarathi"
wrote in message
news:nik_gujarathi.2825yy_1148048124.3395@excelfor um-nospam.com...
Hello frineds,
I was looking for a small macro that will give a error message if the
value of cells in column M & J is same.
Here is the main problem..
This macro should get activated with a check box present in each row.
--
nik_gujarathi
------------------------------------------------------------------------
nik_gujarathi's Profile:
http://www.excelforum.com/member.php...o&userid=34522
View this thread: http://www.excelforum.com/showthread...hreadid=543727