Extract text between double quotes in variable length strings

3gswish

New Member
Joined
Apr 28, 2011
Messages
29
Hi everyone,

A bit of a challenge with this one... The last couple of hours searching have not resulted in a working solution:confused:, so I turn to you.

I have 253 cells in column AO that contain text, containing 1 to 6 chunks of text within "double quotes". Here is an example.

This is text that is "pretty"
This "text" is not "well formed" or well mannered
This "set of words" has been "significantly modified" and is "junk", "junk2" and "junk3"

The length of the text, the length of the quoted chunks, the number of quoted chunks, as well as the location of the quoted chunks within the string are completely variable.

The result I would like to acheive is for each chunk, without it's quotes, to be in the next columns on the same row.

The text is in row AO2:AO254, so chunks should end up in the same row, starting at column AP and higher.

The results would look like

[TABLE="width: 500"]
<tbody>[TR]
[TD]AP[/TD]
[TD]AQ[/TD]
[TD]AR[/TD]
[TD]AS[/TD]
[TD]AT[/TD]
[/TR]
[TR]
[TD]pretty[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]text[/TD]
[TD]well formed[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]set of words[/TD]
[TD]significantly modified[/TD]
[TD]junk[/TD]
[TD]junk2[/TD]
[TD]junk3[/TD]
[/TR]
</tbody>[/TABLE]



Any and all input would be very greatly appreciated - Thank you, Thank you, Thank you! :)
 
Last edited:
I've a short question about your code. How is it possible to split two different columns. In your script we are going to split column "AO". Is it possible to split column "B" in the same script?
 
Upvote 0

Excel Facts

How to find 2nd largest value in a column?
MAX finds the largest value. =LARGE(A:A,2) will find the second largest. =SMALL(A:A,3) will find the third smallest

Forum statistics

Threads
1,223,247
Messages
6,171,007
Members
452,374
Latest member
keccles

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