Specific task. See Attachment.
Thanks!
![]() |
Specific task. See Attachment.
Thanks!
NO other spreadsheets. FIGURE 1 reprsent table before inserting rows and FIGURE 2 after that.
Pajoo, your needs are not clear. There is no explanation of why the values in Figure 2 were inserted.
If this is just a random process, it will be manual.
Also, your use of merged cells for each row not only makes no sense (you can use a single row and simply expand the row height to attain the exact same appearance) but your use of merged cells will interfere with any macro-type assistance we try to offer.
VBA and merged cells do not play nicely with each other. Plus, as I've already said, your table layout gains nothing from the merged cells. The same layout can be attained without them.
Error. See below.
Why the values in Figure 2 were inserted?
Figure 1 is part of larger project that has predefined tables with predefined numbers of rows. Sometimes, really sometimes, table need additional rows and red bordered method (attachment) is acceptable for me.
Forget merged cells.
Thanks!
The red bordered method is not an explained method. It's just a table of letters that don't match anything you've shown in table 1 or table 2.
I can't remember the last time I had this much trouble understanding what someone was trying to do. Sorry, it must be me.
NO, it surely me.Try this one.
Maybe this:
Code:Option Explicit
Sub InsertRows()
'JBeaucaire (11/14/2009)
Dim Cnt As Long
Cnt = Application.WorksheetFunction.CountA(Range("N5:N14"))
If Cnt = 0 Then Exit Sub
Range("A13:K" & 12 + Cnt).Insert Shift:=xlDown
Range("N5:N" & 4 + Cnt).Copy Range("F13")
Range("N5:N14").ClearContents
End Sub
All work fine, but...
Print layout after added rows is not same. How erase number of added rows below double red line.
If I insert, for example, 5 rows, same number of rows (5) I need to erase below double red line.
Thanks!
I can't see how this sample sheet and question relates the to the prior question in any way.
Perhaps this completely different need deserves a thread of its own, it's clear you're starting completely over from what we did above.
All times are GMT -7. The time now is 12:40 PM. |