Forum Discussion

vijaysbhati's avatar
vijaysbhati
Copper Contributor
Sep 09, 2024

excel

arrange one to 100 serial number in one page for printout. actually I have 1 to 1800 Serial number in A and B collum in single row .. how can i fit in C and D and E and F like screen shot

  • Lorenzo's avatar
    Lorenzo
    Silver Contributor

    vijaysbhati 

    Alternatively, with Power Query:

    let
        Source = Excel.CurrentWorkbook(){[Name="Table1"]}[Content],
        TableSplit = Table.Split(Source, 25),
        TablesToColumns = List.Transform(TableSplit, Table.ToColumns),
        Names = List.TransformMany(
            {1..List.Count(TableSplit)}, each Table.ColumnNames(Source),
            (i,name) => Text.Combine({name, Text.From(i)}, " #")
        ),
        TableFromColumns = Table.FromColumns( List.Combine(TablesToColumns), Names )
    in
        TableFromColumns

Resources