Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 44
Default Advance filter to find date wise?

Wish u all a happy x'mas
Hi
I am using Advance Filter for data like...
Date,PartyName,Item,Gross,Mel,Labr.

Sub test()

Sheets("DATA").Select

Range("A5:J600").AdvancedFilter Action:=xlFilterCopy, CriteriaRange:=Range( _
"A1:J2"), CopyToRange:=Range("M5:v5"), Unique:=False


Range("M5:V5").Select
Range(Selection, Selection.End(xlDown)).Select
Range("M5:V30").Select
Selection.Copy
Sheets("Day Report").Select
ActiveSheet.Paste
Range("A2").Select
Sheets("data").Select
Range("A6").Select

End Sub

Where i want to find data list for Date wise like
Date start from 1 oct 05 to 30 oct 05 or so on.
but i am not able to do this. I have record this macro.

Any Help.

thanks

Tiya
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default Advance filter to find date wise?

Tiya,

Instead of using the data as a range, create a new criteria range of say

L1: Date
L2: ="="&DATE(2005,10,1)
L3: "=<="&DATE(2005,10,30)

and then use code of

Range("A5:J600").AdvancedFilter _
Action:=xlFilterCopy, _
CriteriaRange:=Range("J1:J3"), _
CopyToRange:=Range("M5:V5"), _
Unique:=False


--

HTH

RP
(remove nothere from the email address if mailing direct)


"Tiya" wrote in message
...
Wish u all a happy x'mas
Hi
I am using Advance Filter for data like...
Date,PartyName,Item,Gross,Mel,Labr.

Sub test()

Sheets("DATA").Select

Range("A5:J600").AdvancedFilter Action:=xlFilterCopy,

CriteriaRange:=Range( _
"A1:J2"), CopyToRange:=Range("M5:v5"), Unique:=False


Range("M5:V5").Select
Range(Selection, Selection.End(xlDown)).Select
Range("M5:V30").Select
Selection.Copy
Sheets("Day Report").Select
ActiveSheet.Paste
Range("A2").Select
Sheets("data").Select
Range("A6").Select

End Sub

Where i want to find data list for Date wise like
Date start from 1 oct 05 to 30 oct 05 or so on.
but i am not able to do this. I have record this macro.

Any Help.

thanks

Tiya



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
advance filter Alberto Ast[_2_] Excel Discussion (Misc queries) 6 October 10th 09 01:47 AM
Data row wise, formula column wise Fred Smith Excel Discussion (Misc queries) 4 December 9th 05 03:48 PM
Delete row wise duplicates & colomun wise simultaneously excel Dipankar Excel Worksheet Functions 0 October 6th 05 01:14 PM
Advance filter search does not filter an exact match cfiiland Excel Programming 1 June 10th 05 12:44 PM
advance filter DANmcc Excel Discussion (Misc queries) 2 April 20th 05 10:13 PM


All times are GMT +1. The time now is 06:51 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"