ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Code for Tom and Frank (https://www.excelbanter.com/excel-programming/306939-code-tom-frank.html)

dan

Code for Tom and Frank
 
Hi again:

Frank, yours is working now, but my mistake, I would need
inserted not the whole row; just for the 3 columns: sort
of shift cells down; there are other columns after c and I
have autofilter; something like belowlike below...
1 1 OK a
2 2 OK a
b
3 4 NO c
57 7 NO a


Thank you very much,

Dan

PS Tom your did not have a result...


Tom Ogilvy

Code for Tom and Frank
 
PS: Dan, it worked fine for me and the technique is identical to Frank's,
so Don't think the problem is my code - at least not with the information
you presented.

Please try to stay in the thread and not start new threads without context.

--
Regards,
Tom Ogilvy



"Dan" wrote in message
...
Hi again:

Frank, yours is working now, but my mistake, I would need
inserted not the whole row; just for the 3 columns: sort
of shift cells down; there are other columns after c and I
have autofilter; something like belowlike below...
1 1 OK a
2 2 OK a
b
3 4 NO c
57 7 NO a


Thank you very much,

Dan

PS Tom your did not have a result...




Frank Kabel

Code for Tom and Frank
 
Hi
see Tom's response. Not sure what your issue is. Also I totally agree
with tom: Please stay in thhe original thread. Don't worry, we'll read
your response

--
Regards
Frank Kabel
Frankfurt, Germany

"Dan" schrieb im Newsbeitrag
...
Hi again:

Frank, yours is working now, but my mistake, I would need
inserted not the whole row; just for the 3 columns: sort
of shift cells down; there are other columns after c and I
have autofilter; something like belowlike below...
1 1 OK a
2 2 OK a
b
3 4 NO c
57 7 NO a


Thank you very much,

Dan

PS Tom your did not have a result...



dan

Code for Tom and Frank
 
Hi guys:

I understand!

My issue is that I do not want to inser a entire row just
shift the cells down up to column c(including):

1 1 OK a
2 2 OK b
c
3 4 NO d

Thanks,

Dan

-----Original Message-----
Hi
see Tom's response. Not sure what your issue is. Also I

totally agree
with tom: Please stay in thhe original thread. Don't

worry, we'll read
your response

--
Regards
Frank Kabel
Frankfurt, Germany

"Dan" schrieb im

Newsbeitrag
...
Hi again:

Frank, yours is working now, but my mistake, I would

need
inserted not the whole row; just for the 3 columns: sort
of shift cells down; there are other columns after c

and I
have autofilter; something like belowlike below...
1 1 OK a
2 2 OK a
b
3 4 NO c
57 7 NO a


Thank you very much,

Dan

PS Tom your did not have a result...


.


Frank Kabel

Code for Tom and Frank
 
Hi
try:
Sub insert_rows()
Dim lastrow As Long
Dim row_index As Long

lastrow = ActiveSheet.Cells(Rows.count, "C").End(xlUp).row
For row_index = lastrow - 1 To 1 Step -1
If Cells(row_index+1, "C").Value ="No" Then
Cells(row_index + 1, "A").resize(1,3).Insert (xlShiftDown)
End If
Next
End Sub

--
Regards
Frank Kabel
Frankfurt, Germany

"Dan" schrieb im Newsbeitrag
...
Hi guys:

I understand!

My issue is that I do not want to inser a entire row just
shift the cells down up to column c(including):

1 1 OK a
2 2 OK b
c
3 4 NO d

Thanks,

Dan

-----Original Message-----
Hi
see Tom's response. Not sure what your issue is. Also I

totally agree
with tom: Please stay in thhe original thread. Don't

worry, we'll read
your response

--
Regards
Frank Kabel
Frankfurt, Germany

"Dan" schrieb im

Newsbeitrag
...
Hi again:

Frank, yours is working now, but my mistake, I would

need
inserted not the whole row; just for the 3 columns: sort
of shift cells down; there are other columns after c

and I
have autofilter; something like belowlike below...
1 1 OK a
2 2 OK a
b
3 4 NO c
57 7 NO a


Thank you very much,

Dan

PS Tom your did not have a result...


.




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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com