Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 96
Default Autofilter Question

Thank you. THat was a great help. I had to modify it just a little bit so i
could avoid hiding rows in the auto filter i did not want to hide.

Private Sub Worksheet_Change(ByVal Target As Range)

If Not Intersect(Target, Me.Range("A2")) Is Nothing Then

On Error Resume Next
Me.Columns(10).AutoFilter
On Error GoTo 0

Worksheets("Sheet1").Range("A14:C318").AutoFilter field:=3,
Criteria1:=Target.Value

End If

End Sub

"Bob Phillips" wrote:

Private Sub Worksheet_Change(ByVal Target As Range)

If Not Intersect(Target, Me.Range("A2")) Is Nothing Then

On Error Resume Next
Me.Columns(3).AutoFilter
On Error GoTo 0

Me.Columns(3).AutoFilter field:=1, Criteria1:=Target.Value
End If

End Sub



--
---
HTH

Bob


(there's no email, no snail mail, but somewhere should be gmail in my addy)



"Qaspec" wrote in message
...
Can I use VBA to identify the value in a cell and update the autofilter
for a
specific column with that value?

When user types a name into A2 the the autofilter for column c updates to
filter for that name.




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
Autofilter Question kate Excel Discussion (Misc queries) 0 April 25th 08 07:13 PM
another autofilter question Gary Keramidas Excel Programming 3 November 7th 07 08:23 PM
another autofilter question Gary Keramidas Excel Programming 5 December 1st 06 10:43 PM
autofilter question Gary Keramidas[_2_] Excel Programming 2 September 23rd 06 04:25 PM
AUTOFILTER QUESTION Dan Excel Programming 1 March 2nd 05 04:36 PM


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