going forward post your query on the group

Sub test()
Dim i As Long

For i = Sheets(1).Range("a65356").End(xlUp).Row To 2 Step -1
Sheets(1).Select
If Sheets(1).Cells(i, 4).Value = 0 Then

Sheets(1).Cells(i, 4).EntireRow.Delete
End If



If Now() - CDate(Sheets(1).Cells(i, 3).Value) > 90 Then

Rows(i & ":" & i).Copy

Sheets("Above 90 Days").Select
Range("a65356").End(xlUp).Offset(1, 0).Select
ActiveSheet.Paste

ElseIf Now() - CDate(Sheets(1).Cells(i, 3).Value) > 60 Then


Rows(i & ":" & i).Copy

Sheets("Above 60 days").Select
Range("a65356").End(xlUp).Offset(1, 0).Select
ActiveSheet.Paste
ElseIf Now() - CDate(Sheets(1).Cells(i, 3).Value) > 30 Then


Rows(i & ":" & i).Copy

Sheets("Above 30 Days").Select
Range("a65356").End(xlUp).Offset(1, 0).Select
ActiveSheet.Paste
End If


Next i

Sheets("Above 90 Days").Range("a1:j" & Range("a1").End(xlDown).Row).Sort
key1:=Sheets("Above 90 Days").Range("a:a"), order1:=xlAscending,
Header:=xlYes
Sheets("Above 30 Days").Range("a1:j" & Range("a1").End(xlDown).Row).Sort
key1:=Sheets("Above 30 Days").Range("a:a"), order1:=xlAscending,
Header:=xlYes
Sheets("Above 60 days").Range("a1:j" & Range("a1").End(xlDown).Row).Sort
key1:=Sheets("Above 60 days").Range("a:a"), order1:=xlAscending,
Header:=xlYes


End Sub


On Wed, Jun 22, 2011 at 7:23 PM, Manish Bankoti
<genious.fore...@gmail.com>wrote:

>
> Hi Ashish,
>
>  I want data from sheet 1 to copy and paste it in other sheets as per the
> date also they will sort automatically in other sheets and data in sheet1
> whose amount is 0 should be deleted.
>
> Thanks & Regards,
> Manish Singh Bankoti
>



-- 
*Regards*
* *
*Ashish Koul*
*akoul*.*blogspot*.com <http://akoul.blogspot.com/>
http://akoul.posterous.com/
*akoul*.wordpress.com <http://akoul.wordpress.com/>
My Linkedin Profile <http://in.linkedin.com/pub/ashish-koul/10/400/830>


P Before printing, think about the environment.

-- 
----------------------------------------------------------------------------------
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel

Reply via email to