با سلا م و خسته نباشید
فایل اکسلی را به همراه توضیحات ضمیمه کرده ام، خواهشمندم راهنمایی بفرمائید.
باتشکر
فایل اکسلی را به همراه توضیحات ضمیمه کرده ام، خواهشمندم راهنمایی بفرمائید.
باتشکر
Private Sub Worksheet_Change(ByVal Target As Range)
Application.ScreenUpdating = False
Application.EnableEvents = False
Dim rn(1 To 6) As Byte
rn(1) = Range("a" & Rows.Count).End(xlUp).Row
rn(2) = Range("b" & Rows.Count).End(xlUp).Row
rn(3) = Range("c" & Rows.Count).End(xlUp).Row
rn(4) = Range("d" & Rows.Count).End(xlUp).Row
rn(5) = Range("e" & Rows.Count).End(xlUp).Row
rn(6) = Range("f" & Rows.Count).End(xlUp).Row
lstr = Application.WorksheetFunction.Max(rn)
With Range("A" & lstr & ":f" & lstr)
.Font.Name = "Calibri"
.Font.Size = 11
.Font.Strikethrough = False
.Font.Super****** = False
.Font.Sub****** = False
.Font.OutlineFont = False
.Font.Shadow = False
.Font.Underline = xlUnderlineStyleNone
.Font.ThemeColor = xlThemeColorLight1
.Font.TintAndShade = 0
.Font.ThemeFont = xlThemeFontMinor
.Borders(xlDiagonalDown).LineStyle = xlNone
.Borders(xlDiagonalUp).LineStyle = xlNone
.Borders(xlEdgeLeft).LineStyle = xlContinuous
.Borders(xlEdgeLeft).ColorIndex = xlAutomatic
.Borders(xlEdgeLeft).TintAndShade = 0
.Borders(xlEdgeLeft).Weight = xlHairline
.Borders(xlEdgeTop).LineStyle = xlContinuous
.Borders(xlEdgeTop).ColorIndex = 0
.Borders(xlEdgeTop).TintAndShade = 0
.Borders(xlEdgeTop).Weight = xlThin
.Borders(xlEdgeBottom).LineStyle = xlDash
.Borders(xlEdgeBottom).ColorIndex = 0
.Borders(xlEdgeBottom).TintAndShade = 0
.Borders(xlEdgeBottom).Weight = xlThin
.Borders(xlEdgeRight).LineStyle = xlContinuous
.Borders(xlEdgeRight).ColorIndex = xlAutomatic
.Borders(xlEdgeRight).TintAndShade = 0
.Borders(xlInsideVertical).LineStyle = xlContinuous
.Borders(xlInsideVertical).ColorIndex = xlAutomatic
.Borders(xlInsideVertical).TintAndShade = 0
.Borders(xlInsideVertical).Weight = xlHairline
.Borders(xlInsideHorizontal).LineStyle = xlNone
.HorizontalAlignment = xlCenter
.VerticalAlignment = xlCenter
.WrapText = False
.Orientation = 0
.AddIndent = False
.IndentLevel = 0
.ShrinkToFit = False
.ReadingOrder = xlContext
.Interior.Pattern = xlNone
.Interior.TintAndShade = 0
.Interior.PatternTintAndShade = 0
End With
Application.EnableEvents = True
Application.ScreenUpdating = True
End Sub
With Range("c3" & ":e" & lstr)
.NumberFormat = "$ #,##0_-"
.Font.Bold = True
End With
کامنت