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

try something like this, dont cut n paste directly to your real workboo
as im new at this and this may not act as you wish!!

Private Sub Workbook_SheetSelectionChange(ByVal sh As Object, ByVa
Target As Range)
Dim myrange As Range
Dim t1 As String
Dim I1 As Integer
Dim res As Variant


If sh.Name = "THE SHEET NAME YOUR LIST IS ON GOES HERE" Then Exi
Sub
Set myrange = sh.Range("THE RANGE TO WORK ON")
If Not Intersect(myrange, Target) Is Nothing Then
With Worksheets("SHEET THE LIST IS ON")
t1=inputbox ("looking/entering matches","Match additio
box",""
res = Application.Match(t1, .Range(.Range("A2"), _
.Range("A2").End(xlDown)), 0)
End With
If Not IsError(res) Then
ActiveCell = t1

Exit Sub
Worksheets("SHEET NAME YOUR LIST IS ON").Visible = False
End If

I1 = MsgBox("Please try again " & vbCrLf & _
"" Entry not recognised ")
If ActiveCell < "SHEET NAME " Then
End If
End If
End Sub

Probably isnt exactly what you want, but it may be useful to you!

Simon

--
Message posted from http://www.ExcelForum.com

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
Extracting all matches Blue Max Excel Worksheet Functions 2 July 2nd 09 08:35 PM
Searching, matching then searching another list based on the match A.S. Excel Discussion (Misc queries) 1 December 13th 06 05:08 AM
matches LBTeacher Excel Discussion (Misc queries) 3 November 12th 05 03:51 AM
matches Ray Newman via OfficeKB.com Excel Discussion (Misc queries) 3 February 7th 05 11:09 PM
Looking for matches Bill C[_4_] Excel Programming 2 April 13th 04 05:43 PM


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