Attribute VB_Name = "Foglio28"
Attribute VB_Base = "0{00020820-0000-0000-C000-000000000046}"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = True
Attribute VB_TemplateDerived = False
Attribute VB_Customizable = True
Private Sub Worksheet_Change(ByVal Target As Range)
Dim run_number As Integer

'------------------------------------------------------
'Temperatures and pressures Enter
'------------------------------------------------------
For run_number = 1 To 16
If run_number = 1 Then
i = 7
Else: i = i + 14
End If
'-------------------
If Target.Address = Cells(i, 17).Address Then Cells(i, 18).Select 'temp
If Target.Address = Cells(i, 18).Address Then Cells(i, 19).Select
If Target.Address = Cells(i, 19).Address Then Cells(i + 4, 15).Select
'end of air temp
'-------------------
If Target.Address = Cells(i + 4, 15).Address Then Cells(i + 4, 17).Select
If Target.Address = Cells(i + 4, 17).Address Then Cells(i + 5, 15).Select
If Target.Address = Cells(i + 5, 15).Address Then Cells(i + 5, 17).Select
If Target.Address = Cells(i + 5, 17).Address Then Cells(i + 6, 14).Select
'end of cold pressures

'-------------------
If Target.Address = Cells(i + 6, 14).Address Then Cells(i + 6, 15).Select
If Target.Address = Cells(i + 6, 15).Address Then Cells(i + 6, 16).Select
If Target.Address = Cells(i + 6, 16).Address Then Cells(i + 6, 17).Select
If Target.Address = Cells(i + 6, 17).Address Then Cells(i + 6, 18).Select
If Target.Address = Cells(i + 6, 18).Address Then Cells(i + 6, 19).Select
If Target.Address = Cells(i + 6, 19).Address Then Cells(i + 7, 14).Select
If Target.Address = Cells(i + 7, 14).Address Then Cells(i + 7, 15).Select
If Target.Address = Cells(i + 7, 15).Address Then Cells(i + 7, 16).Select
If Target.Address = Cells(i + 7, 16).Address Then Cells(i + 7, 17).Select
If Target.Address = Cells(i + 7, 17).Address Then Cells(i + 7, 18).Select
If Target.Address = Cells(i + 7, 18).Address Then Cells(i + 7, 19).Select
If Target.Address = Cells(i + 7, 19).Address Then Cells(i + 8, 15).Select
'end of hot temps

'-------------------
If Target.Address = Cells(i + 8, 15).Address Then Cells(i + 8, 17).Select
If Target.Address = Cells(i + 8, 17).Address Then Cells(i + 9, 15).Select
If Target.Address = Cells(i + 9, 15).Address Then Cells(i + 9, 17).Select
If Target.Address = Cells(i + 9, 17).Address Then Cells(i + 11, 16).Select
'end of hot pressures

Next run_number




'------------------------------------------------------
'Sectors Enter
'------------------------------------------------------
If Columns("G").Hidden = False Then

For i = 1 To 300
    For j = 4 To 6
    If Target.Address = Cells(i, j).Address Then Cells(i, j + 1).Select
    Next j
Next i
For i = 7 To 300
    If Target.Address = Cells(i, 7).Address Then Cells(i + 1, 4).Select
Next i
End If

If Columns("G").Hidden = True Then

For i = 1 To 300
    For j = 4 To 5
    If Target.Address = Cells(i, j).Address Then Cells(i, j + 1).Select
    Next j
Next i
For i = 7 To 300
    If Target.Address = Cells(i, 6).Address Then Cells(i + 1, 4).Select
Next i
End If



End Sub

