여기 B에서 빈 식을 작성하는 샘플입니다, C 및 D마다 선택이 변경 :에서 ThisWorkbook에서
:
Private Sub Workbook_SheetSelectionChange(ByVal Sh As Object, ByVal Target As Range)
Dim oSh As Worksheet, oUsed As Range, oRng As Range
Set oSh = Sh
Set oUsed = oSh.UsedRange.Columns("B")
'only add to blank formulas
Set oRng = oUsed.Find("", LookIn:=xlFormulas)
Do While Not oRng Is Nothing
'B formula
oRng.Offset(, 0).FormulaR1C1 = "=RC[-1] + 100"
'C formula
oRng.Offset(, 1).FormulaR1C1 = "=RC[-1] + 100"
'D formula
oRng.Offset(, 2).FormulaR1C1 = "=RC[-1] + 100"
Set oRng = oUsed.Find("", oRng, xlFormulas)
Loop
End Sub
이 통합 문서에 에있는 모든 워크 시트를 작동, 따라서 현재 시트를 테스트 할 수 있습니다.
이있어되지 않습니다 .... 개인 서브 Worksheet_Change (ByVal의 다른 이름으로 대상 범위) Target.Column는 = 3 그런 다음 Application.ScreenUpdating 사용 = 거짓 적용합니다. 계산 = xlCalculationManual Sheet2.Cells (Target.Row 5) .Formula 문 = "XXX = (" "XXX" ","& Target.Address & ", E5)" Application.ScreenUpdating 사용 = TRUE Application.Calculation = xlCalculationAutomat ic 최종면 End Sub – stan
원한다면 스스로 응답 할 수 있습니다. –