?
Solved

How to Copy and Paste Visible Cells only

Posted on 2013-11-07
3
Medium Priority
?
906 Views
Last Modified: 2013-11-10
Hi Guys, in Excel if I want to copy a cell and paste the contents from the Cell down other cells in a Auto-Filtered Column. How do I do it without pasting over the Hidden rows?
0
Comment
Question by:Justincut
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 35

Expert Comment

by:Norie
ID: 39630678
You could use SpecialCells(xlCellTypeVisible) to return only the visible cells in the range you want to copy to.

For example, copy D1 to visible cells in B2:B100.

Range("D1").Copy Range("B2:B100").SpecialCells(xlCellTypeVisible)

Open in new window

0
 
LVL 4

Expert Comment

by:LCCSAM
ID: 39630745
Here is the microsoft write-up for what you are asking. The "Go To Special..." function is what you are looking for.

There is also a keyboard shortcut for this but it seems to be slipping my mind today.

http://office.microsoft.com/en-us/excel-help/copy-visible-cells-only-HA010244897.aspx
0
 
LVL 33

Accepted Solution

by:
Rob Henson earned 2000 total points
ID: 39630856
When copying a single cell and pasting into a filtered range, the default will be to only paste into visible cells anyway. Likewise using Ctrl+D to Fill Down will only populate visible rows.

The problem comes when you are copying a range of more than one cell. When pasting that it will paste into the same sized contiguous range.

Thanks
Rob H
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
After seeing numerous questions for Dynamic Data Validation I notice that most have used Visual Basic to solve the problem. This suggestion is purely formula based and can be used in multiple rows.
Graphs within dashboards are meant to be dynamic, representing data from a period of time that will change each time the dashboard is updated with new data. Rather than update each graph to point to a different set within a static set of data, t…
This Micro Tutorial will demonstrate in Google Sheets how to use the HYPERLINK function to create live links inside your spreadsheet.

649 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question