Insert one new copy row
Closed
ravenyaad
Posts
2
Registration date
Tuesday 27 May 2014
Status
Member
Last seen
30 May 2014
-
27 May 2014 à 13:59
ravenyaad Posts 2 Registration date Tuesday 27 May 2014 Status Member Last seen 30 May 2014 - 30 May 2014 à 07:55
ravenyaad Posts 2 Registration date Tuesday 27 May 2014 Status Member Last seen 30 May 2014 - 30 May 2014 à 07:55
Related:
- How to insert specific number of rows at fixed intervals in excel
- How do i find a specific video on youtube - Guide
- Number to words in excel - Guide
- Insert key - Guide
- Count number of occurrences in excel - Guide
- Insert check mark in word - Guide
2 responses
venkat1926
Posts
1863
Registration date
Sunday 14 June 2009
Status
Contributor
Last seen
7 August 2021
811
30 May 2014 à 02:09
30 May 2014 à 02:09
try this macro
Sub test()
Dim j As Integer, k As Integer
j = Cells(Rows.Count, "A").End(xlUp).Row
For k = j To 2 Step -1
If Cells(k, "Y") = "y" Then Cells(k, "Y").EntireRow.Insert
Next k
End Sub
ravenyaad
Posts
2
Registration date
Tuesday 27 May 2014
Status
Member
Last seen
30 May 2014
30 May 2014 à 07:55
30 May 2014 à 07:55
Thank you very much for your attention
This code can not solve my problem,I was able to solve the first part
((i can add a new row when the condition is met))
like
"Sub AddRows()
Dim lLoop As Long
Dim rFound As Range
With Range("k:k")
Set rFound = .Cells(3, 1)
For lLoop = 1 To WorksheetFunction.CountIf(.Cells, "y")
Set rFound = .Cells.Find("y", rFound, xlValues, , , xlNext, False)
rFound(2, 1).EntireRow.Insert
Next lLoop
End With
End Sub"
The second part is very difficult for me....
i need when insert new row to copy 5cell from
The previous row which have the condition in cell y3
Excuse me if my English is not good
Because it is not my native language
Thank you again :)
This code can not solve my problem,I was able to solve the first part
((i can add a new row when the condition is met))
like
"Sub AddRows()
Dim lLoop As Long
Dim rFound As Range
With Range("k:k")
Set rFound = .Cells(3, 1)
For lLoop = 1 To WorksheetFunction.CountIf(.Cells, "y")
Set rFound = .Cells.Find("y", rFound, xlValues, , , xlNext, False)
rFound(2, 1).EntireRow.Insert
Next lLoop
End With
End Sub"
The second part is very difficult for me....
i need when insert new row to copy 5cell from
The previous row which have the condition in cell y3
Excuse me if my English is not good
Because it is not my native language
Thank you again :)