Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 39
Default Find a Cell Value (Revised)

Hello,

I'm just trying to write code that will find a cell value from one sheet to
another. On Sheet1, I want say cell "B11" to be what I'm looking for(what
ever value that is in cell "B11" is the value that I'm looking to find on
Sheet2). On Sheet2, I need it to search through say range "C1:C5001" and have
it select the first one it finds. How would I go about doing that?

Thanks

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 595
Default Find a Cell Value (Revised)

Gabe wrote:
I'm just trying to write code that will find a cell value from one
sheet to another. On Sheet1, I want say cell "B11" to be what I'm
looking for(what ever value that is in cell "B11" is the value that
I'm looking to find on Sheet2). On Sheet2, I need it to search
through say range "C1:C5001" and have it select the first one it
finds. How would I go about doing that?


Gabe:

dim rFound as Range

Set rFound = sheet2.Range("C1:C5001").Find(Sheet1.Range("B11"). Value)

If Not rFound Is Nothing Then
Debug.Print rFound.Address
End If

See http://www.dicks-blog.com/archives/2...e-find-method/ for more
on Find.

--
Dick Kusleika
MVP-Excel
www.dailydoseofexcel.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
Can I insert in a cell the "date revised" (in a worksheet,etc) WendyT Excel Worksheet Functions 1 June 26th 09 09:10 PM
display revised total in Office 2003 when cell data changes Kerry_y Excel Discussion (Misc queries) 1 November 15th 06 05:43 PM
Format excel to revised date automatically when revised annetteberrios Excel Programming 0 September 2nd 05 02:25 PM
n or U Revised ? Blessingspoint Excel Worksheet Functions 1 January 18th 05 08:43 PM
Revised btnprint1_click() Bruce Roberson Excel Programming 8 July 25th 03 10:23 PM


All times are GMT +1. The time now is 10:50 AM.

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"