Posts by dangle

    Re: VBA Code to sort worksheets based on a pre-sorted named-range


    RPerkins


    This may need adjusting to suit your range:


    Re: VBA, how to reference several cells in one line [ tidy code ]


    Yes you can tidy this up a fair bit. Try to avoid using 'select' on ranges. It is unncessary and slows down the code. It is better to refer to the range directly or use a 'with' statement.


    Try this:

    Code
    If List.Exists(.Cells(Rw, "A").Value) Then
                .Cells(Rw, 2).Resize(, 3).ClearContents
                With .Cells(Rw, 3).Resize(, 3).Interior
                    .Pattern = xlSolid
                    .PatternThemeColor = xlThemeColorDark1
                    .ThemeColor = xlThemeColorDark1
                    .TintAndShade = -0.149998474074526
                    .PatternTintAndShade = -0.149998474074526
                End With
            End If

    Re: Macro to break work in column to letter per column


    Hello Excel_DJ


    Maybe a formula such as:
    =MID($A$1,COLUMN(A1),1)
    change the range and drag to the right


    Code could be:

    Code
    Sub Splitter()
    Dim i As Integer
    With Range("a1")  '<< Adjust to your range
        For i = 1 To Len(.Value)
            .Offset(, i) = Mid(.Value, i, 1)
        Next
    End With
    End Sub


    Or else, please explain more or post a file.

    Re: Split multiple lines in multiple cells


    Hello cardmstr and welcome to Ozgrid


    How about?


    Re: Transpose columns to rows via macros/vba


    Srisansan


    Does this achieve what you want?


    Re: Copying rows based on specific criteria


    Does this work for you?

    Re: Copying rows based on specific criteria


    Hello Ryan


    Does your final output data include positive values from column L - i.e. you search for all negative values in column L first and then search again for all rows with grant numbers that you identified in the initial search?

    Re: Combine and calculate based on string patterns


    You could do this with a formula:


    =IFERROR(SUMPRODUCT(--(LEFT($B$2:$B$8,FIND("-",B2)-1)=LEFT(B2,FIND("-",B2)-1))*($D$2:$D$8)*($F$2:$F$8))/SUMIF($B$2:$B$8,LEFT(B2,FIND("-",B2)-1)&"*",$F$2:$F$8),"")


    (Copy to H2 and fill down)


    But if you wanted VB:


    Re: Listing of &quot;Formula 1&quot; Racing Teams


    I think it's going to have to be VBA solution:


    Re: Generating a Final List From Multiple Sheets in Alphabetical Order Using A Macro


    Hello Richard


    A possible macro which might help:



    There are plenty of help/training files on OzGrid itself if you want to delve into VBA further.

    Re: seach duplicate and little more


    Yes I saw the screenshot. Perhaps I should be clearer. Please upload a sample workbook. Screenshots are not very helpful as no one is going to recreate your data.