View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
joel joel is offline
external usenet poster
 
Posts: 9,101
Default Find and copy range from one workbook to another

You don't have to use find. find becomes complicated when you need to find
all the items. this is much simplier code

summaryRow = 1
for RowCount = 1 to 2000
if Range("B" & RowCount).value = 2214 then
'add your code to copy reults
Range("B" & RowCount).copy _
destination:=sheets("Summary").Range("A" & Summaryrow)
Summaryrow = Summary + 1
end if
next RowCount

"Mifty" wrote:

Hi,

I realise that this is a big ask because I've been searching through all the
other posts similar to this question.

Here's what I did. Results Workbook Sheet1 Cell M1 = Ref number = 2214. So I
started recording a macro and copied M1 and put into FIND dialogue box then
opened Data Workbook and repeated the FIND then copied row adjacent to the
cell that had been found to paste into the Results Workbook. Even as I was
recording the macro I realised that I would just be telling the macro to
search for "2214" and probably just copying the range specified as well.

I've been reading though other posts and I can see that it is so much more
complicated than I had imagined and that I would have to specify ranges and
so much more and even pinching ideas here and there would not be enough

If anyone could help with some code I would be more than grateful and if it
could be done in such a way that I could try to figure out what it's doing
that would be brilliant
TIA
--
Mifty