OpenOffice.org Forum at OOoForum.orgThe OpenOffice.org Forum
 
 [Home]   [FAQ]   [Search]   [Memberlist]   [Usergroups]   [Register
 [Profile]   [Log in to check your private messages]   [Log in

[solved]extract <img src="alphanumeric string.jpg /&

 
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Calc
View previous topic :: View next topic  
Author Message
slabo
General User
General User


Joined: 27 Jul 2010
Posts: 5

PostPosted: Tue Jul 27, 2010 5:01 am    Post subject: [solved]extract <img src="alphanumeric string.jpg /& Reply with quote

Hi,
I want to extract
Quote:
<img src="0a0eee796e4b81106935241d7b51d60c.jpg" />

into column B and
Quote:
[sound:8e3ea08f826a28f4a9efa7d661a8471d.mp3]
into column C from
Quote:
<img src="0a0eee796e4b81106935241d7b51d60c.jpg" /><br />What's this?[sound:8e3ea08f826a28f4a9efa7d661a8471d.mp3]

for all the cells in column A . The rest should go to column D.
I looked at regular expressions, but syntax is different for OpenOffice and i could use some help.
Any help appreciated,
Thanks.


Last edited by slabo on Tue Jul 27, 2010 7:23 pm; edited 1 time in total
Back to top
View user's profile Send private message
ken johnson
Super User
Super User


Joined: 23 Apr 2009
Posts: 1875
Location: Sydney, Australia

PostPosted: Tue Jul 27, 2010 5:57 am    Post subject: Reply with quote

If A1 has...
Code:
<img src="0a0eee796e4b81106935241d7b51d60c.jpg" /><br />What's this?[sound:8e3ea08f826a28f4a9efa7d661a8471d.mp3]

then
Code:
=LEFT(A1;FIND(">";A1))
returns
Code:
<img src="0a0eee796e4b81106935241d7b51d60c.jpg" />

and
Code:
=MID(A1;FIND("[";A1);255)
returns
Code:
[sound:8e3ea08f826a28f4a9efa7d661a8471d.mp3]

If the first formula is in B1 and the second formula is in C1 then
Code:
=SUBSTITUTE(SUBSTITUTE(A1;B1;"");C1;"")
returns
Code:
<br />What's this?


Ken Johnson
_________________
If your problem has been solved please add "[Solved]" to the beginning of your first post title (edit button).
Back to top
View user's profile Send private message
slabo
General User
General User


Joined: 27 Jul 2010
Posts: 5

PostPosted: Tue Jul 27, 2010 7:21 pm    Post subject: Reply with quote

Thanks for the quick reply.
Works, no need for regular expressions.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Calc All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group