VBA to create new lines of data

jmewebb

New Member
Joined
Dec 6, 2012
Messages
43
Office Version
  1. 365
Platform
  1. Windows
1625664922813.png


Data separated by a comma in column "I" need to create a new row as shown under "Convert to:". The original data file already contains approximately 200k rows. I had another code but it took hours to run.
 
BINGO!!! We have a winner! Finally got it to work. Thank you so very much for all of your expertise!
You are welcome.

So what ended up being the issue?
It is helpful for us to know, for future reference, so we know what kind of things can happen and what suggestions to make.
 
Upvote 0

Excel Facts

Difference between two dates
Secret function! Use =DATEDIF(A2,B2,"Y")&" years"&=DATEDIF(A2,B2,"YM")&" months"&=DATEDIF(A2,B2,"MD")&" days"
You are welcome.

So what ended up being the issue?
It is helpful for us to know, for future reference, so we know what kind of things can happen and what suggestions to make.
It was user error. I needed to move my data to Sheet1 and rename it. I'm sure there was a work around in the code but I don't know how to do that.
 
Upvote 0
It was user error. I needed to move my data to Sheet1 and rename it. I'm sure there was a work around in the code but I don't know how to do that.
You could simply just change the name of the sheet in the code in the line that assigns the sheet name to "ws1".
Rich (BB code):
    Set ws1 = Sheets("Sheet1")
If you change "Sheet1" there to whatever the name of your sheet is, it will filter done to the rest of the code (since we are using Worksheet objects).
 
Upvote 0

Forum statistics

Threads
1,214,920
Messages
6,122,269
Members
449,075
Latest member
staticfluids

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