![]() |
Automate Formula script
I am looking for a way to use script to say if there is data in A place
=B1+C1 in D of the same row. |
Automate Formula script
Sub formularizer()
For Each r In Intersect(ActiveSheet.UsedRange, Range("A:A")) If IsEmpty(r) Then Else n = r.Row r.Offset(0, 3).Formula = "=B" & n & "+C" & n End If Next End Sub -- Gary''s Student - gsnu200909 |
Automate Formula script
Would this go in the sheet code?
These are the actual formulas I am using =A55-WEEKDAY(A55,2)+1 =A55-DAY(A55)+1 Thank you "Gary''s Student" wrote: Sub formularizer() For Each r In Intersect(ActiveSheet.UsedRange, Range("A:A")) If IsEmpty(r) Then Else n = r.Row r.Offset(0, 3).Formula = "=B" & n & "+C" & n End If Next End Sub -- Gary''s Student - gsnu200909 |
Automate Formula script
For your initial query.
Range("D1:D10").Formula = "=IF(A1<"""",B1+C1,"""")" If this post helps click Yes --------------- Jacob Skaria "Jeremy" wrote: Would this go in the sheet code? These are the actual formulas I am using =A55-WEEKDAY(A55,2)+1 =A55-DAY(A55)+1 Thank you "Gary''s Student" wrote: Sub formularizer() For Each r In Intersect(ActiveSheet.UsedRange, Range("A:A")) If IsEmpty(r) Then Else n = r.Row r.Offset(0, 3).Formula = "=B" & n & "+C" & n End If Next End Sub -- Gary''s Student - gsnu200909 |
All times are GMT +1. The time now is 06:22 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com