View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Aaron1978[_17_] Aaron1978[_17_] is offline
external usenet poster
 
Posts: 1
Default Adding data to a cell via VBA


Here is my first attempt but I keep getting a runrime error '1004'. Any
ideas?


Option Explicit

Dim BackFillConstant As Single
Dim FlowStress As Single
Dim Charpy As Single
Dim FractureArea As Single
Dim Pressure As Single
Dim ArrestPressure As Single


Private Sub Worksheet_Change(ByVal Target As Range)

BackFillConstant = Range("K").Value
FlowStress = Range("FlowStress").Value
Charpy = Range("CV").Value
FractureArea = Range("A").Value
Pressure = Range("P").Value
ArrestPressure = Range("ArrestPressure").Value


If Target.Address = "$A$1" Then
If IsNumeric(Target) Then
'Range("B1") = Target.Value + 2
Range("B1") = fnFractureVelocity(BackFillConstant,
FlowStress, Charpy, FractureArea, Pressure, ArrestPressure)
End If
End If
End Sub


--
Aaron1978
------------------------------------------------------------------------
Aaron1978's Profile: http://www.excelforum.com/member.php...o&userid=31201
View this thread: http://www.excelforum.com/showthread...hreadid=546244