ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Custom paste macro (https://www.excelbanter.com/excel-programming/296092-custom-paste-macro.html)

Floss

Custom paste macro
 
Objective:
To be able to paste a selected area of date from one worksheet of a different workbook into a specific starting location. The data needs to be inserted as values and cannot overwrite the data below the starting insert location.

What I tryied:
Paste Special (values) gets me the values I want but overwrites other data in worksheet.

Insert copied cells seems to work but it brings over all the formula and formatting from other workbook that I dont need.

Hoping there maybe a macro solution for this. I started a "paste" macro on the target worksheet but need help with coding instructions to actually paste or insert the data as noted in the objective. Imported data will be accessed by other worksheets of the workbook so I don't think that pasting as object will work, which I didnot try for that reason.

Any help, links or sugestions will be greatly appreciated.
Thank you all in advance.
Floss.

Greg Koppel

Custom paste macro
 
Hi Floss,

How about counting the rows in your selection and then inserting that many
rows into the destination worksheet and then pasting the data?

HTH, Greg

"floss" wrote in message
...
Objective:
To be able to paste a selected area of date from one worksheet of a

different workbook into a specific starting location. The data needs to be
inserted as values and cannot overwrite the data below the starting insert
location.

What I tryied:
Paste Special (values) gets me the values I want but overwrites other data

in worksheet.

Insert copied cells seems to work but it brings over all the formula and

formatting from other workbook that I dont need.

Hoping there maybe a macro solution for this. I started a "paste" macro

on the target worksheet but need help with coding instructions to actually
paste or insert the data as noted in the objective. Imported data will be
accessed by other worksheets of the workbook so I don't think that pasting
as object will work, which I didnot try for that reason.

Any help, links or sugestions will be greatly appreciated.
Thank you all in advance.
Floss.




daniels012[_3_]

Custom paste macro
 
Sheets("Data").Select
Range("B8").Select 'Cell where you want to enter data
Selection.EntireRow.Insert ' Opens a free row to put Data
Range("B8").Selec

--
Message posted from http://www.ExcelForum.com



All times are GMT +1. The time now is 01:25 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com