How do you get Excel to refresh data on Worksheet from within VBA?

M

mike

How do you get spreadsheet data in Excel to recalculate itself from
within VBA, without the need of just changing a cell value on the
worksheet?



Private Sub Worksheet_SelectionChange(ByVal Target As Range)

With Cells(6, "k")
If Cells(7, "f") = "Open" Then
If Cells(6, "k") <= Cells(7, "d") Then
Cells(7, "f") = "Filled"
End If
End If
End With

End Sub


I have cell: K6 connected to an external price feed that changes
automatically.

Your help on this is greatly appreciated.

Thank you

Mike Stafford
 
J

jamescox

Possibly overkill, but check out Application.CalculateFull and
Application.CalculateFullRebuild in the help or VB IDE Object Browser.
 
Top