LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
ksp ksp is offline
external usenet poster
 
Posts: 1
Default Insert Rows with Border Formatting


Hi All

I have a macro that inserts a blank row where it finds any text in
column A (code below), is it possible to insert this line with a border
on the top edge for columns A thru to J bearing in mind I have existing
borders to the left and right that I do not want to impact upon (NB the
left edge of column A and the right edge of column J are heavier weights
than the other sides)

Thaks in advance

ksp


Sub InsertRows()

With Range("A10:A2499")
On Error Resume Next
Set C = .Find(What:="*", LookIn:=xlValues)
If Not C Is Nothing Then
firstaddress = C.Offset(1, 0).Address
Do
C.Offset(0, 0).EntireRow.Insert
Set C = .FindNext(C)
Loop While Not C Is Nothing And C.Address < firstaddress
End If

End With

End Sub


--
ksp
------------------------------------------------------------------------
ksp's Profile: http://www.excelforum.com/member.php...fo&userid=6267
View this thread: http://www.excelforum.com/showthread...hreadid=537681

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Conditional Formatting - Thick Border? fedude Excel Worksheet Functions 6 February 23rd 10 03:28 PM
Conditional formatting border thickness simonc Excel Discussion (Misc queries) 1 December 29th 09 11:16 AM
Insert a border into a header or footer in Excel 2007 ktyn Excel Discussion (Misc queries) 0 December 2nd 09 05:59 PM
Lost Border Formatting CW Excel Discussion (Misc queries) 0 July 6th 06 09:17 PM
Formatting a footer with a top border-line Ed Isenberg Excel Discussion (Misc queries) 3 December 19th 04 10:41 PM


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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"