Quantcast
Channel: Active questions tagged excel - Stack Overflow
Viewing all articles
Browse latest Browse all 88809

Save data to a particular cell with vlookup

$
0
0

On sheet1 I have a cell that displays notes I have one cell with a drop down list for years and another with a drop down that has the months. The third cell displays the notes for the year and month. I built the cod to display the correct month and years notes. what I would like to know how to do is once the notes appear in the cell I would like to be able to changed the notes or add to the notes then have that saved to the table it is pulling from so if I go back to that month and years notes it shows up with the changes. Here is the code that pulls the information from the other sheet and displays it.

Private Sub Worksheet_Change(ByVal Target As Range)

    On Error Resume Next

        If Range(Year, Month) Is Nothing Then Exit Sub

    On Error GoTo 0

    If Not Intersect(Target, Range(Year, Month)) Is Nothing Then

        Range("E14").Formula = [VLOOKUP(F6,'Super Admin'!A1118:M1221,MATCH(J6,'Super Admin'!A1118:M1118,0),0)]
        Range("E14").Activate
        SendKeys "{F2}"
        Application.ScreenUpdating = True
    End If

End Sub

Viewing all articles
Browse latest Browse all 88809

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>