ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Macro to insert a row, copy info from another row and autosize the row (https://www.excelbanter.com/excel-programming/284334-macro-insert-row-copy-info-another-row-autosize-row.html)

Price

Macro to insert a row, copy info from another row and autosize the row
 
I have a macro that will copy and paste one row to the current row
(the selected row).

However I would like it to insert a row instead of copying over the
current row.

And I would like it to resize the row to a specified size.

Your assistance is appeciated.

Paul B[_6_]

Macro to insert a row, copy info from another row and autosize the row
 
Price, try adding this to your code
Selection.EntireRow.Insert
ActiveCell.RowHeight = 20.25


--
Paul B
Always backup your data before trying something new
Please post any response to the newsgroups so others can benefit from it
Feedback on answers is always appreciated!
Using Excel 2000 & 97
** remove news from my email address to reply by email **
"Price" wrote in message
om...
I have a macro that will copy and paste one row to the current row
(the selected row).

However I would like it to insert a row instead of copying over the
current row.

And I would like it to resize the row to a specified size.

Your assistance is appeciated.




Price

Macro to insert a row, copy info from another row and autosize the row
 
gracias Paul!

david mcritchie

Macro to insert a row, copy info from another row and autosize the row
 
Hi K. Price,
Even though your question was answered and you thanked
Paul for the answer ...

I have the feeling that you wanted to copy information to that
empty row when you asked for.how to insert a row. In fact
that is more clearly written in your subject. The subject should
only reiterate what is asked for in a question. The question should
be complete without having to look again at the subject.

Take a look at
Insert a Row using a Macro to maintain formulas
http://www.mvps.org/dmcritchie/excel/insrtrow.htm

which may give you some additional material. I don't know how
resize fits into your plan, so you may be looking for a total or
something else.
---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"Price" wrote in message om...
gracias Paul!





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

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