S Suri New Member Oct 2, 2012 #1 I Have Cantain Name Like "Nowebsite". I want to create next blank Row. Example:- xxxxx xxxxx NO WEBSITE "I need blank row" xxxxx XXXXX XXXXX XXXXX XXXXX XXXXX XXXXX NO WEBSITE "I need blank row" XXXXX NO WEBSITE "I need blank row" Like I want plz let mee any vba code.......
I Have Cantain Name Like "Nowebsite". I want to create next blank Row. Example:- xxxxx xxxxx NO WEBSITE "I need blank row" xxxxx XXXXX XXXXX XXXXX XXXXX XXXXX XXXXX NO WEBSITE "I need blank row" XXXXX NO WEBSITE "I need blank row" Like I want plz let mee any vba code.......
K kaushik03 Member Oct 2, 2012 #2 Hi Suri, Assuming you have data at sheet4 as follows: NO WEBSITE s d e NO WEBSITE s d e r t NO WEBSITE sc d f NO WEBSITE y Now please paste the following code in a standard module and run it. This should insert a blank row after the word NO WEBSITE. Sub AddBlankRows() Dim lngRow As Long '// Assuming data is at Sheet4 - Change to suit For lngRow = Sheet4.UsedRange.Rows.Count To 1 Step -1 '// Assuming Column A, change to suit If UCase$(Sheet4.Cells(lngRow, 1).Value) = "NO WEBSITE" Then Sheet4.Range("A" & CStr(lngRow + 1)).Select Selection.EntireRow.Insert , CopyOrigin:=xlFormatFromLeftOrAbove End If Next End Sub Kaushik
Hi Suri, Assuming you have data at sheet4 as follows: NO WEBSITE s d e NO WEBSITE s d e r t NO WEBSITE sc d f NO WEBSITE y Now please paste the following code in a standard module and run it. This should insert a blank row after the word NO WEBSITE. Sub AddBlankRows() Dim lngRow As Long '// Assuming data is at Sheet4 - Change to suit For lngRow = Sheet4.UsedRange.Rows.Count To 1 Step -1 '// Assuming Column A, change to suit If UCase$(Sheet4.Cells(lngRow, 1).Value) = "NO WEBSITE" Then Sheet4.Range("A" & CStr(lngRow + 1)).Select Selection.EntireRow.Insert , CopyOrigin:=xlFormatFromLeftOrAbove End If Next End Sub Kaushik