How to separate rest day and work day period in a month by vba

shi353

New Member
Joined
Dec 10, 2016
Messages
7
Have a string like
"1/1,1/2R,1/3,1/4,1/5,1/6R,1/7R,1/8,1/9,1/10,1/11,1/12,1/13R,1/14,1/15R,1/16,1/17,1/18R,1/19R,1/20,1/21,1/22,1/23,1/24,1/25R,1/26R,1/27,1/28,1/29,1/30,1/31R"
Want use split to 1D array convert to a result below show by msgbox
"1/1(1),1/2R,1/3~1/5(3),1/6R,1/7R,1/8~1/12(5),1/13R,1/14(1),1/15R,1/16~1/17(2),1/19R…."
 

Excel Facts

Can you AutoAverage in Excel?
There is a drop-down next to the AutoSum symbol. Open the drop-down to choose AVERAGE, COUNT, MAX, or MIN
There is a chance you might get a suggestion if you explained what all those numbers/letters/symbols mean and exactly what the result should be and how that result would be achieved if doing it manually.
As it stands, both strings you have posted are meaningless to me.
 
Upvote 0
P1.jpg
 
Upvote 0
The result I want is use vba to convert [A2] string to [A4] string
I still have no idea how A2 string is converted to A4 string. Can you explain step-by-step how you would do it manually?
 
Upvote 0

Forum statistics

Threads
1,215,193
Messages
6,123,560
Members
449,108
Latest member
rache47

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