+ Reply to Thread
Results 1 to 3 of 3

If false then go to next cell

  1. #1
    Registered User
    Join Date
    02-21-2012
    Location
    Walthem, MA
    MS-Off Ver
    Excel 2003
    Posts
    1

    If false then go to next cell

    Hi All,

    I have a data like below but it not standered keep changing (with live data dont where Flase row will come). If it is Flase then should leave one row as balnk or empty and start from next row. I would like to have if statement. Please could you guys help me out.


    20
    19
    18
    17
    16
    15
    14
    13
    12
    11
    10
    FALSE
    8
    7
    FALSE
    5
    4
    3
    FALSE
    1


    out put like

    20
    19
    18
    17
    16
    15
    14
    13
    12
    11
    10
    -- Blank
    FALSE
    8
    7
    -- Blank
    FALSE
    5
    4
    3
    -- Blank
    FALSE
    1

    Thank you,
    Rama.

  2. #2
    Forum Expert
    Join Date
    03-23-2004
    Location
    London, England
    MS-Off Ver
    Excel 2019
    Posts
    7,080

    Re: If false then go to next cell

    Post your workbook, it's diffcult to understand your problem.
    Regards
    Special-K

    Ensure you describe your problem clearly, I have little time available to solve these problems and do not appreciate numerous changes to them.

  3. #3
    Valued Forum Contributor
    Join Date
    02-09-2012
    Location
    Mauritius
    MS-Off Ver
    Excel 2007
    Posts
    1,055

    Re: If false then go to next cell

    Hello...

    You can try this macro:

    Sub addrow()
    Dim i As Integer

    i = 1
    While Range("A" & i).Value <> ""
    If Range("A" & i).Value = "False" Then
    Rows(i & ":" & i).Select
    Selection.Insert Shift:=xlDown, CopyOrigin:=xlFormatFromLeftOrAbove
    i = i + 1
    End If
    i = i + 1
    Wend
    End Sub

    Please note: I have assumed that the data provided by you is in column A.

    Regards...

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1