ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Trouble formatting Row Height while using a Copy/Paste Macro (https://www.excelbanter.com/excel-programming/347170-trouble-formatting-row-height-while-using-copy-paste-macro.html)

MK@Hartford

Trouble formatting Row Height while using a Copy/Paste Macro
 
I have a series of Button Objects that each reference a specific Cell
and pastes that cell to a different sheet within the Workbook. (There
are additional macros "searching for the next available cell in a
column as well, all working well) My problem is that some of the cells
contain more than 255 characters and once pasted, all you see on the
final page is either a cut off version (because the row doesn't expand)
or "#################". Is there any way I can either format the
specific range of cells or something I can add in my code to allow the
expansion of the Rows when the Text exceeds the existing row height?


Jim Cone

Trouble formatting Row Height while using a Copy/Paste Macro
 
Mike,

Set the RowHeight of the receiving cell the same as the copied cell...
Worksheets(1).Range("B2").EntireRow.RowHeight = _
Worksheets(2).Range("B5").EntireRow.RowHeight

Jim Cone
San Francisco, USA


"MK@Hartford" wrote in message
oups.com
I have a series of Button Objects that each reference a specific Cell
and pastes that cell to a different sheet within the Workbook. (There
are additional macros "searching for the next available cell in a
column as well, all working well) My problem is that some of the cells
contain more than 255 characters and once pasted, all you see on the
final page is either a cut off version (because the row doesn't expand)
or "#################". Is there any way I can either format the
specific range of cells or something I can add in my code to allow the
expansion of the Rows when the Text exceeds the existing row height?



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

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