Proporcjonalna czcionka Temat: Re: Find(what:=select.range(
Autor: markos97 Data: 18 Sty 2008
Odwołania: 1
Witam! Właśnie znalezłem [ www.pcreview.co.uk/forums/thread-999890.php ] macro: Sub SELECTVALUES() Dim c As Range Dim d As Range Dim FirstAddress As String Dim myFindString As String myFindString = "99" With ActiveSheet.Range("A:D") Set c = .Find(myFindString, LookIn:=xlValues, lookAt:=xlWhole) If Not c Is Nothing Then Set d = c FirstAddress = c.Address End If Set c = .FindNext(c) If Not c Is Nothing And c.Address <> FirstAddress Then Do Set d = Union(d, c) Set c = .FindNext(c) Loop While Not c Is Nothing And c.Address <> FirstAddress End If End With d.Select End Sub Jego "wadą" jest, że znajduje (find 4 cells in the select columns that have the same value, "99"): A B C D 1 99 99 99 99 ... w takiej A 1 99 2 99 3 99 4 itd. ...oraz takiej konfiguracji "the corresponding cells"; znajduje też pojedyńcze komórki o tej samej wartości "99" (co mnie jednak zupełnie nie interesuje); potrafi też znaleźć układy diagonalne, o które mi wyłącznie chodzi; nie wiem, może ktoś coś jeszcze z tego sensownego wysamży, będę dozgonnie rad; póki co (szukam na własną rękę w GOOGLE) do zobaczenia z pozdrowieniami
Wysłano z serwisu Usenet w portalu Gazeta.pl -> http://www.gazeta.pl/usenet/