View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Desert Piranha[_42_] Desert Piranha[_42_] is offline
external usenet poster
 
Posts: 1
Default Insert formula with code dynamically


Crowbar via OfficeKB.com Wrote:
Dim LastRow As Long
Dim RowNdx As Long
Dim OldVal As String

LastRow = Cells(Rows.Count, "I").End(xlUp).Row
OldVal = Range("C1")
For RowNdx = 5 To LastRow
If Cells(RowNdx, "I").Value = "" Then
Cells(RowNdx, "C").Value = OldVal
Else
OldVal = Cells(RowNdx, "C").Value
End If
Next RowNdx

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...ing/200601/1Hi Crowbar,


I'v played with this for an hour or so. Haven't had any sucess yet,
will keep trying and post back.


--
Desert Piranha


------------------------------------------------------------------------
Desert Piranha's Profile: http://www.excelforum.com/member.php...o&userid=28934
View this thread: http://www.excelforum.com/showthread...hreadid=504764