Results 1 to 2 of 2

Thread: Automatically copy data from one worksheet to another based on current month

  1. #1
    Seeker Kihoro's Avatar
    Join Date
    Sep 2012
    Location
    Nairobi, Kenya, Kenya
    Posts
    6
    Articles
    0

    Automatically copy data from one worksheet to another based on current month



    Register for a FREE account, and/
    or Log in to avoid these ads!

    hi guys
    i would like to copy data from the table in worksheet 'pending stocks' to the worksheet 'historical data' based on current month. eg all data range B4:E15 that has E.T.A details as September 2012 or any month before September 2012 should be copied to worksheet 'historical data' if the current system month is equal to September 2012.
    is this possible?
    please find attached
    i hope i have explained my question well.

    thanks in advance.

    sincerely

    john kihoro
    Attached Files Attached Files

  2. #2
    Neophyte cherambane's Avatar
    Join Date
    May 2012
    Location
    Karnataka, India
    Posts
    4
    Articles
    0
    Try This.


    Code:
    Private Sub tester()
    
    Sheets("pending stocks").Select
    Range("B4").AutoFilter Field:=4, Criteria1:="<=" & Str(Date)
    Range("Table2").Select
    Selection.SpecialCells(xlCellTypeVisible).Select
    Selection.Copy
    Sheets("historicaldata").Select
    ActiveSheet.Paste
    
    End Sub
    Regards,

    Basheer Cherambane (India)


    Quote Originally Posted by Kihoro View Post
    hi guys
    i would like to copy data from the table in worksheet 'pending stocks' to the worksheet 'historical data' based on current month. eg all data range B4:E15 that has E.T.A details as September 2012 or any month before September 2012 should be copied to worksheet 'historical data' if the current system month is equal to September 2012.
    is this possible?
    please find attached
    i hope i have explained my question well.

    thanks in advance.

    sincerely

    john kihoro

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •