LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Filtering for exact text

I am trying to filter a large report, using two parameters, Planner Code and Status. Everything works fine, except one of the 4 planner codes I am filtering by, TEAMC 1, is bringing back not only that but TEAMC 11, TEAMC 12, etc...

The macro:

Does the advanced filter, by inserting the filter parameters, (Westak, Team C1*, ViaSystems, and TTM
' and only for "Released" parts.
'
Rows("1:1").Select
Selection.Insert Shift:=xlDown
Selection.Insert Shift:=xlDown
Selection.Insert Shift:=xlDown
Selection.Insert Shift:=xlDown
Selection.Insert Shift:=xlDown
Selection.Insert Shift:=xlDown
Range("C1").Select
ActiveCell.FormulaR1C1 = "Planner"
Range("C2").Select
ActiveCell.FormulaR1C1 = "Westak"
Range("C3").Select
ActiveCell.FormulaR1C1 = "TEAMC 1"
Range("C4").Select
ActiveCell.FormulaR1C1 = "ViaSystems"
Range("C5").Select
ActiveCell.FormulaR1C1 = "TTM"
Range("D1").Select
ActiveCell.FormulaR1C1 = "Status"
Range("D2").Select
ActiveCell.FormulaR1C1 = "Released"
Range("D3").Select
ActiveCell.FormulaR1C1 = "Released"
Range("D4").Select
ActiveCell.FormulaR1C1 = "Released"
Range("D5").Select
ActiveCell.FormulaR1C1 = "Released"
Range("C8").Select
Range("A7:N25006").AdvancedFilter Action:=xlFilterCopy, CriteriaRange:= _
Range("C1:D5"), CopyToRange:=Range("AA5"), Unique:=False
End Sub


The line that is causing me trouble is:

ActiveCell.FormulaR1C1 = "TEAMC 1"

I have tried insering "=TEAMC 1", as the help screen under "Filter by using advanced criteria" suggested, but this just stalls out the macro. I have also tried leaving a space: "TEAMC 1 ", thinking that would rule out the second number, mush like it does in the Find/Replace function; this returned nothing at all, not even TEAMC 1....

The wildcard characters also are of no help, as they don't cover a case where you want nothing after a certain character.

Help!!!
 
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
Using VLookup when text isn't an exact match Ken K Excel Worksheet Functions 3 November 2nd 13 08:54 PM
Routine to find exact Row matches in Col1 Col2 Col3 but exact offsetting numbers in Col4 [email protected] Excel Discussion (Misc queries) 0 June 11th 08 11:30 PM
How can I exact no. from text string? E.g ACBE123445te Poonam Excel Worksheet Functions 6 April 5th 08 03:10 AM
TEST FOR EXACT TEXT Phil B Excel Worksheet Functions 8 October 29th 06 11:51 PM
Vlookup where text not exact Janicej Excel Discussion (Misc queries) 2 August 19th 06 08:57 PM


All times are GMT +1. The time now is 12:23 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"