macro arrange duplicated data based on column

Mussa

Board Regular
Joined
Jul 12, 2021
Messages
241
Office Version
  1. 2019
  2. 2010
hello
I have data from COL A: E contain duplicates names in COL B . so what I want macro arrange the data below the duplicate names based on col B .
the result should be from COL K: O
ARRANGE.xlsm
ABCDEFGHIJKLMNOP
1DATENAMEINVOICE NOORDER NOTOTALDATENAMEINVOICE NOORDER NOTOTAL
21/1/2021KALL1INV1000RD10002,000.001/1/2021KALL1INV1000RD10002,000.00
31/2/2021KALL2INV1001RD10013,000.001/10/2021KALL1INV1009RD10092,000.00
41/3/2021KALL3INV1002RD10024,000.001/19/2021KALL1INV1018RD10181,500.00
51/4/2021KALL4INV1003RD10035,000.001/2/2021KALL2INV1001RD10013,000.00
61/5/2021KALL5INV1004RD10046,000.001/11/2021KALL2INV1010RD10102,500.00
71/6/2021KALL6INV1005RD10052,500.001/3/2021KALL3INV1002RD10024,000.00
81/7/2021KALL7INV1006RD10064,500.001/12/2021KALL3INV1011RD10113,500.00
91/8/2021KALL8INV1007RD10073,500.001/4/2021KALL4INV1003RD10035,000.00
101/9/2021KALL9INV1008RD10081,000.001/13/2021KALL4INV1012RD10122,500.00
111/10/2021KALL1INV1009RD10092,000.001/5/2021KALL5INV1004RD10046,000.00
121/11/2021KALL2INV1010RD10102,500.001/14/2021KALL5INV1013RD10131,500.00
131/12/2021KALL3INV1011RD10113,500.001/6/2021KALL6INV1005RD10052,500.00
141/13/2021KALL4INV1012RD10122,500.001/15/2021KALL6INV1014RD10141,500.00
151/14/2021KALL5INV1013RD10131,500.001/7/2021KALL7INV1006RD10064,500.00
161/15/2021KALL6INV1014RD10141,500.001/16/2021KALL7INV1015RD10151,500.00
171/16/2021KALL7INV1015RD10151,500.001/8/2021KALL8INV1007RD10073,500.00
181/17/2021KALL8INV1016RD10161,500.001/17/2021KALL8INV1016RD10161,500.00
191/18/2021KALL9INV1017RD10171,500.001/9/2021KALL9INV1008RD10081,000.00
201/19/2021KALL1INV1018RD10181,500.001/18/2021KALL9INV1017RD10171,500.00
SHEET1

thanks in advance
 

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
Try this with a copy of your workbook

VBA Code:
Sub CopyAndSort()
  With Range("A1").CurrentRegion.Offset(, 10)
    .Value = .Offset(, -10).Value
    .Sort Key1:=.Columns(2), Order1:=xlAscending, Key2:=.Columns(1), Order2:=xlAscending, Key3:=.Columns(3), Order3:=xlAscending, Header:=xlYes
  End With
End Sub
 
Upvote 0
Solution
great ! it's short and quick answer
many thanks for your answering :)
 
Upvote 0
You're welcome. Thanks for the follow-up. :)
 
Upvote 0

Forum statistics

Threads
1,215,363
Messages
6,124,505
Members
449,166
Latest member
hokjock

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top