LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default "Insert LineBreak-Macro"Thanks BOB!

Hey Bob!

Thanks a ton! The macro worked!

I know I'm pushing my luck, but is there anyway I can enter
value(-111) inside the blank cells of the first 4 columns once the
have been created using this macro?

Your Macro:

Sub InsertBlanks()
Dim i As Long
For i = Cells(Rows.Count, "A").End(xlUp).Row To 2 Step -1
If Cells(i, "A").Value < Cells(i - 1, "A").Value Then
Cells(i, "A").EntireRow.Insert
i = i - 1 ' skip new line
End If
Next i
End Sub

I have changed the column"A" to "C" as I need that to check for th
incremental number within that column and introduce the blank row. No
in the 4 columns I would require the value -111 to be introduced usin
the same macro.

This is my actual requirment:
25.345085 51.367877 1 0
25.784345 50.356682 1 0
-111 -111 -111 -111
66.179288 47.117222 2 0
66.164537 47.128142 2 0
-111 -111 -111 -111


Any suggestions?

Thanks a lot!
Verne

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

 
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
Insert "Find dialog box" edits into macro danno-c[_2_] Excel Discussion (Misc queries) 3 September 24th 09 05:40 PM
Macro to Insert Current Date into cell - Macro to "Save As" Guy[_2_] Excel Worksheet Functions 4 December 12th 08 08:20 PM
Lost "File Menu" - now it's "Edit / View / Insert.." but no "F daves Excel Discussion (Misc queries) 3 April 24th 07 04:52 AM
Insert "-" in text "1234567890" to have a output like this"123-456-7890" Alwyn Excel Discussion (Misc queries) 3 October 25th 05 11:36 PM
Macro to insert "0" in front of 4 character string Lowell B. Copeland[_2_] Excel Programming 2 August 29th 03 03:43 PM


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

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

About Us

"It's about Microsoft Excel"