سلام با این کد شما هر جای سلول ها کلیک کنید یا متنی قرار بدین در ستون A شماره ردیف میزنه
کد:
Option ExplicitPrivate Sub Worksheet_SelectionChange(ByVal Target As Excel.Range) Dim RowOffset As Long Dim IndexCol As String 'Set values RowOffset = 0 'Change the A to the column where you want the numbers to show IndexCol = "A" Intersect(ActiveCell.EntireRow, Columns(IndexCol)).Value = ActiveCell.Row + RowOffset End Sub