One option, put in the worksheet change event. You will have to modify to meet your specific information.
Private Sub Worksheet_Change(ByVal Target As Range)
Dim ws As Worksheet: Set ws = Sheets("Sheet1") '<==your sheet name goes here
If Not Intersect(Target, ws.Range("A28")) Is Nothing Then
Select Case Target.Value
Case "test1" '<== your first value goes here
Call Emailshowreq
Case "test2" '<== your second value goes here
Call Emailstraightruckreq
'you can contine on for multiple cases if needed
End Select
End If
End Sub
If you don't want this as a worksheet change and want it only done when you want to run it as a macro then
Sub Macro1()
Dim ws As Worksheet: Set ws = Sheets("Sheet1") '<==your sheet name goes here
Select Case ws.Range("A28").Value
Case "test1" '<== your first value goes here
Call Emailshowreq
Case "test2" '<== your second value goes here
Call Emailstraightruckreq
'you can contine on for multiple cases if needed
End Select
End Sub
Bookmarks