strangebiscuit
New Member
- Joined
- Nov 25, 2013
- Messages
- 35
Hi, I've got what seems like a simple conversion task that I'm having trouble puzzling out.
I have a column of product descriptions (text/html) that contain measurements (i.e. "Medium - 6.3cm x 7cm") and I need to find and convert them from cm to inches. I'm having trouble figuring out how to grab the numbers before the "cm" so I can convert them.
I'm fine to do a search/replace for the actual unit of measurement (i.e. changes "cm" to "inches"), but how do I isolate and convert just the numbers that come before the unit?
Would be happy to just do this as a formula in an adjacent column if possible and copy/paste the whole thing, but also fine to use a macro if it makes it easier to figure out.
There are no spaces between the numbers and the unit of measurement.
Need to end up with something like this:
[TABLE="width: 500"]
<tbody>[TR]
[TD][TABLE="width: 393"]
<colgroup><col></colgroup><tbody>[TR]
[TD]Small 7cm x 4.5cm - blah blah blah[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD][TABLE="width: 393"]
<colgroup><col></colgroup><tbody>[TR]
[TD]Small 17.8in x 11.4in - blah blah blah[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[/TR]
[TR]
[TD][TABLE="width: 393"]
<colgroup><col></colgroup><tbody>[TR]
[TD]Medium 11.5cm x 7cm - blah blah blah[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD]Medium 4.5cin x 2.6in - blah blah blah[TABLE="width: 500"]
<tbody></tbody>[/TABLE]
[/TD]
[/TR]
[TR]
[TD][TABLE="width: 393"]
<colgroup><col></colgroup><tbody>[TR]
[TD]Range: from 5cm x 5cm to 15cm x 5cm. Blah blah blah[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD]Range: from 2in x 2in to 5.9in x 2in. Blah blah blah[/TD]
[/TR]
</tbody>[/TABLE]
Thanks in advance for any tips you can provide, greatly appreciated!
I have a column of product descriptions (text/html) that contain measurements (i.e. "Medium - 6.3cm x 7cm") and I need to find and convert them from cm to inches. I'm having trouble figuring out how to grab the numbers before the "cm" so I can convert them.
I'm fine to do a search/replace for the actual unit of measurement (i.e. changes "cm" to "inches"), but how do I isolate and convert just the numbers that come before the unit?
Would be happy to just do this as a formula in an adjacent column if possible and copy/paste the whole thing, but also fine to use a macro if it makes it easier to figure out.
There are no spaces between the numbers and the unit of measurement.
Need to end up with something like this:
[TABLE="width: 500"]
<tbody>[TR]
[TD][TABLE="width: 393"]
<colgroup><col></colgroup><tbody>[TR]
[TD]Small 7cm x 4.5cm - blah blah blah[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD][TABLE="width: 393"]
<colgroup><col></colgroup><tbody>[TR]
[TD]Small 17.8in x 11.4in - blah blah blah[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[/TR]
[TR]
[TD][TABLE="width: 393"]
<colgroup><col></colgroup><tbody>[TR]
[TD]Medium 11.5cm x 7cm - blah blah blah[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD]Medium 4.5cin x 2.6in - blah blah blah[TABLE="width: 500"]
<tbody></tbody>[/TABLE]
[/TD]
[/TR]
[TR]
[TD][TABLE="width: 393"]
<colgroup><col></colgroup><tbody>[TR]
[TD]Range: from 5cm x 5cm to 15cm x 5cm. Blah blah blah[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD]Range: from 2in x 2in to 5.9in x 2in. Blah blah blah[/TD]
[/TR]
</tbody>[/TABLE]
Thanks in advance for any tips you can provide, greatly appreciated!