PC Review


Reply
Thread Tools Rate Thread

Copy from one sheet paste to another

 
 
Eric
Guest
Posts: n/a
 
      21st Feb 2008
Helo all,

On sheets("Test Database") I have 2,000 tests spanning from column A to AD.
these tests are of different mix types. In Column B is the mix type.

On sheets("main menu") in cell ("B9") I have a mix number 4064 which is
choosen from a drop down box consisting of 28 different number (4052-4079).

What I need to do is when sheets("main menu") range("B9") has a number I
need the last 4 tests from sheets("Tests Database") that match sheets("main
menu") range("B9") to copy all the rows (A-AD) over to another sheet called
sheet("Last 4").

ie:
sheets("main menu").Range("B9")=4064

sheets("test database") looks like this:
A B C D.......
4064
4064~~~> This row would post on to sheets("Last 4")
4052
4052
4064~~~> This row would post on to sheets("Last 4")
4052
4064~~~> This row would post on to sheets("Last 4")
4064~~~> This row would post on to sheets("last 4")

Column "A" is the date the test was run......

Does this make any sense? Any help would be appreciated.......Eric
 
Reply With Quote
 
 
 
 
Joel
Guest
Posts: n/a
 
      21st Feb 2008
Sheets("Test Database").Columns("B:B").AutoFilter
Sheets("Test Database").Cells.AutoFilter Field:=1, _
Criteria1:=Sheets("main menu").Range("B9")
Sheets("Test Database").Rows.SpecialCells(xlCellTypeVisible).Copy
Sheets("Last 4").Rows(1).PasteSpecial

"Eric" wrote:

> Helo all,
>
> On sheets("Test Database") I have 2,000 tests spanning from column A to AD.
> these tests are of different mix types. In Column B is the mix type.
>
> On sheets("main menu") in cell ("B9") I have a mix number 4064 which is
> choosen from a drop down box consisting of 28 different number (4052-4079).
>
> What I need to do is when sheets("main menu") range("B9") has a number I
> need the last 4 tests from sheets("Tests Database") that match sheets("main
> menu") range("B9") to copy all the rows (A-AD) over to another sheet called
> sheet("Last 4").
>
> ie:
> sheets("main menu").Range("B9")=4064
>
> sheets("test database") looks like this:
> A B C D.......
> 4064
> 4064~~~> This row would post on to sheets("Last 4")
> 4052
> 4052
> 4064~~~> This row would post on to sheets("Last 4")
> 4052
> 4064~~~> This row would post on to sheets("Last 4")
> 4064~~~> This row would post on to sheets("last 4")
>
> Column "A" is the date the test was run......
>
> Does this make any sense? Any help would be appreciated.......Eric

 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Copy Paste from Class Sheet to Filtered List on Combined Sheet prkhan56@gmail.com Microsoft Excel Programming 6 16th Sep 2008 04:30 PM
Help to code Macro to Copy fron one sheet and paste in other sheet kay Microsoft Excel Programming 3 25th Jul 2008 06:46 PM
Copy from one Sheet and paste on another sheet based on condition Prem Microsoft Excel Misc 2 24th Dec 2007 05:05 AM
Active Cell Copy And Paste Sheet to Sheet =?Utf-8?B?QS5SLkogQWxsYW4gSmVmZmVyeXM=?= Microsoft Excel New Users 4 4th May 2006 02:04 AM
automatic copy and paste from sheet to sheet in a workbook =?Utf-8?B?cmFtc2V5anJhbXNleWo=?= Microsoft Excel Programming 6 11th Dec 2004 12:37 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 11:30 AM.