Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 74
Default Find Method ; search area


Hi Group,

Have below code. ActiveSheet is WorkSheets(1). Is this the correct syntax
for the "search area"? Seems not to work.

Thanks for any hints.

Brgds

CG Rosén

Dim d
With Worksheets(4).Range("B1:B100") '????????
Set d = .Find(ComboBox1.Text, LookIn:=xlValues)
If d Is Nothing Then
MsgBox "OK"
Else
MsgBox "NIL"
End If
End With


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 96
Default Find Method ; search area

Hi

Try this

With Worksheets(1).Range("B1:B100")
Set d = .Find(combobox1.text, LookIn:=xlValues)
If Not d Is Nothing Then
firstaddress = d.Address
MsgBox "OK"
Else
MsgBox "NIL"
End If
End With


You don't need to dim d as you are setting it.

-----Original Message-----

Hi Group,

Have below code. ActiveSheet is WorkSheets(1). Is this

the correct syntax
for the "search area"? Seems not to work.

Thanks for any hints.

Brgds

CG Rosén

Dim d
With Worksheets(4).Range

("B1:B100") '????????
Set d = .Find(ComboBox1.Text, LookIn:=xlValues)
If d Is Nothing Then
MsgBox "OK"
Else
MsgBox "NIL"
End If
End With


.

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
SUMPRODUCT search versus other method Serge Excel Discussion (Misc queries) 3 November 13th 06 09:14 AM
Method of selecting an area with a macro WildGlio Excel Worksheet Functions 1 March 25th 05 06:55 PM
The find method Stuart[_6_] Excel Programming 0 August 5th 03 03:14 PM
Help with the Find method Mike NG Excel Programming 3 August 4th 03 07:15 PM
The Find Method Brad[_7_] Excel Programming 0 July 16th 03 03:23 PM


All times are GMT +1. The time now is 11:16 PM.

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

About Us

"It's about Microsoft Excel"