Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 216
Default Copy and Find

Hi. I am relatively new to VB ...

Part of my subroutine needs to accomplish the following:

1. Copy the activecell in file1 to memory.
2. Go to file2 (already open) and search for and find the
same value.
3. Move down 1 cell from that location

Any help?

Thanks,
Mike.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 24
Default Copy and Find

Try this:

Memory1 = ActiveCell.Value
Workbooks(file2).Activate
Cells.Find(What:=Memory1, After:=ActiveCell, _
LookIn:= xlValues, LookAt:=xlPart, _
SearchOrder:=xlByRows).Select
ActiveCell.Offset(1,0).Select

You may want to change xlValues to xlFormulas if the Find
does not work. You also may want to change xlPart to
xlWhole if you start finding things that contain what you
are looking for but are not exactly the item you want.

-----Original Message-----
Hi. I am relatively new to VB ...

Part of my subroutine needs to accomplish the following:

1. Copy the activecell in file1 to memory.
2. Go to file2 (already open) and search for and find the
same value.
3. Move down 1 cell from that location

Any help?

Thanks,
Mike.
.

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
Copy contents of Find (Find and Replace) rob_bob Excel Discussion (Misc queries) 0 March 26th 09 11:01 PM
Find in XML and Copy S1L1Y1 Excel Discussion (Misc queries) 0 May 19th 08 05:50 PM
Find and Copy Help Excel Discussion (Misc queries) 2 February 28th 08 09:54 PM
Find and Copy QPapillon Excel Discussion (Misc queries) 4 September 25th 06 10:09 PM
Find and copy?? L/P Excel Worksheet Functions 1 January 14th 05 06:29 PM


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