I have the following code:
Dim FinalAddr As Range
Dim Final As String
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Cells.Count > 1 Then Exit Sub
On Error Resume Next
Select Case UCase(Target.Value)
Case "NEW-BOX"
Selection.Offset(-1, 2).Select
FinalAddr = Range(Selection.Address)
MsgBox FinalAddr ' Debug, nothing comes up however
Selection.ClearContents
Selection.Offset(1, -2).Select
Case "END-BOX"
Final = FinalAddr.Value
Application.Speech.Speak (Final)
End Select
End Sub
However, when I scan new box nothing happens, is all of the syntax correct? I get no errors, any input will be greatly appreciated.
Case "NEW-BOX"?Case Else: MsgBox "You provided " & UDase(Target.Value)before theEnd Selectstatement to see what is being checked.