View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Mark Dullingham Mark Dullingham is offline
external usenet poster
 
Posts: 92
Default Selecting Cells on two worksheets

Look for the MATCH function in th VB Help files and use it to search an array
for you text string, the result will then be the cell you select in the code
I posted.

Sorry I haven't time to write and test a bit of code, this is a flying
visit, hopefully it put you in the right direction

Mark

"stewart" wrote:

that is kind of what i wanted but i need to search for a text string
that is on Sheet 1 and then select that cell on both sheets. I wont
actually know what the exact cell location is when i type my code



On Mar 4, 10:17 pm, "Gary Keramidas" <GKeramidasATmsn.com wrote:
one way

Sub test2()
Dim ws1 As Worksheet
Dim ws2 As Worksheet
Set ws1 = Worksheets("Sheet1")
Set ws2 = Worksheets("Sheet2")

ws1.Select
ws2.Select False
Range("A4").Select
End Sub

--

Gary

"stewdizzle" wrote in message

oups.com...

In my workbook i have VB code to select a specific cell based on
specific criteria. How can I select the corresponding cell on another
worksheet. For example I want to find cell A4 on Sheet 1 and select
both that cell and Cell A4 on Sheet2