+ Reply to Thread
Results 1 to 2 of 2

vba to cut and paste into newsheet through 3 condition on 3 column

  1. #1
    Forum Contributor
    Join Date
    04-30-2013
    Location
    washington
    MS-Off Ver
    Excel 2019
    Posts
    168

    vba to cut and paste into newsheet through 3 condition on 3 column

    Dear Experts

    I want the vba code to cut and paste from master to new sheet through 3 condition...

    I usally download report from month day1 till next month day1 so i want make first condition select day of first in col c:c

    IF Condition First In C:C Select Ist Data Of Every Month Select# = 1ST MARCH ( it might get chance for nextmonth report 1st april till 1stmay)
    IF Condition Second In B:B After 12:00 Am Till 8:30 Morning Like(00:00 Till 08:30) Select# = 00:00 TILL 08:30
    IF Condition Three In G:G Both B And D Select# = B AND D

    pls find the attachment you may understand what am i looking for
    Attached Files Attached Files

  2. #2
    Forum Contributor
    Join Date
    04-30-2013
    Location
    washington
    MS-Off Ver
    Excel 2019
    Posts
    168

    Re: vba to cut and paste into newsheet through 3 condition on 3 column

    any experts help on this code?

    Sub deletion()
    Dim a, i As Long

    a = Range("a1").CurrentRegion

    With Application
    .ScreenUpdating = False
    For i = UBound(a) To 2 Step -1
    If VBA.Day(a(i, 3)) = 1 And Format(a(i, 2), "hh:mm") >= "00:00" And Format(a(i, 2), "hh:mm") <= "08:30" Then
    Rows(i).EntireRow.Delete
    End If
    Next
    .ScreenUpdating = True
    End With
    End Sub

    i want apply 3rd condition along with the code any one can help me?
    Last edited by johnlara; 04-20-2015 at 02:19 PM. Reason: help

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Cut data from master and paste into next newsheet depends upon value of a col vba
    By breadwinner in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 04-21-2015, 12:36 PM
  2. [SOLVED] Range.Cut Paste on NewSheet
    By dlow in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-23-2015, 03:10 PM
  3. [SOLVED] copy and paste values to another sheet if value in one column matches condition
    By KK1234 in forum Excel Programming / VBA / Macros
    Replies: 13
    Last Post: 11-05-2013, 11:36 AM
  4. Copy Data between 2 dates and paste it newsheet
    By Knowledge is Wealth in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 09-10-2013, 09:57 AM
  5. Condition Paste Formula in Column N based on Column A
    By tek9step in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 09-07-2009, 04:58 PM

Tags for this Thread

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1