Skip to main content
Support is Offline
Today is our off day. We are taking some rest and will come back stronger tomorrow
Official support hours
Monday To Friday
From 09:00 To 17:30
  Monday, 29 October 2018
  0 Replies
  3K Visits
0
Votes
Undo
Hello, help needed.

I have a sub. running based on cell value in B5. Efter cell value is entered and enter is pressed the workbook opens a mail and sends information about cell value in A2 and A5. Also depending on value in B5(1-11) it sends the corresponding value in A19-A29.

What I now want it to do is to store the values in sheet2. For every time the value in B5 is altered a line consisting of
Date; A2; corresponding A19-A29 and A5 shall be created in sheet2. With the most recent on top.

Possible?


Private Sub Worksheet_Change(ByVal Target As Range)
On Error Resume Next
'If Target.Cells.Count > 1 Then Exit Sub
Set xRg = Intersect(Range("B5"), Target)
If xRg Is Nothing Then Exit Sub
If IsNumeric(Target.Value) And Target.Value = 1 Then
Call Mail_small_Text_Outlook1
End If
If IsNumeric(Target.Value) And Target.Value = 2 Then
Call Mail_small_Text_Outlook2
End If
If IsNumeric(Target.Value) And Target.Value = 3 Then
Call Mail_small_Text_Outlook3
End If
If IsNumeric(Target.Value) And Target.Value = 4 Then
Call Mail_small_Text_Outlook4
End If
If IsNumeric(Target.Value) And Target.Value = 5 Then
Call Mail_small_Text_Outlook5
End If
If IsNumeric(Target.Value) And Target.Value = 6 Then
Call Mail_small_Text_Outlook6
End If
If IsNumeric(Target.Value) And Target.Value = 7 Then
Call Mail_small_Text_Outlook7
End If
If IsNumeric(Target.Value) And Target.Value = 8 Then
Call Mail_small_Text_Outlook8
End If
If IsNumeric(Target.Value) And Target.Value = 9 Then
Call Mail_small_Text_Outlook9
End If
If IsNumeric(Target.Value) And Target.Value = 10 Then
Call Mail_small_Text_Outlook10
End If
If IsNumeric(Target.Value) And Target.Value = 11 Then
Call Mail_small_Text_Outlook11
End If
End Sub



Thanks Jerry
There are no replies made for this post yet.