Value to remain until new value is entered

  • Thread starter Thread starter Dug4
  • Start date Start date
D

Dug4

=IF(Changes!C$10=1,Changes!B$13,IF(Changes!C$10<>1,""))

The way it is now:
Places a value of the cell contains a "1"
and nothing if it does not equal a "1".

Would like:
The value to remain the same until the next time a "1" is entered.

For example:
If a "1" is entered on sheet 1 the value of another cell on sheet 1
is placed on sheet 2.
I want that value (on sheet 2) to remain the same until the
information on sheet 1 is changed again.

What do I enter to keep the value on sheet 1 the same until a
new value is entered?

Thx much
 
Hi
for this you'll need VBA. Put the following code in your worksheet
module of your "Changes" worksheet
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Cells.Count > 1 Then Exit Sub
If Intersect(Target, Me.Range("C10")) Is Nothing Then Exit Sub
On Error GoTo CleanUp:
With Target
If .Value = 1 Then
Application.EnableEvents = False
Worksheets("sheet2").Range("a1").Value = Range("B13").Value
End If
End With
CleanUp:
Application.EnableEvents = True
End Sub
 
Back
Top