robhepworth

Inserting " in a calculation

Discussion created by robhepworth on Mar 28, 2012
Latest reply on Mar 29, 2012 by comment

Hi there,

 

I wonder if anyone can help.

 

The main problem is that I have 6 fields in FM 11 which all contain single URLS. I have created a 7th field which will hold the calculation of the 6 URLS. currently they look a bit like this in basic terms:

 

Field 1 http://www.website.co.uk/pictures/IMG_0804.jpg

 

 

 

Field 2 http://www.website.co.uk/pictures/IMG_0805.jpg

Field 3 http://www.website.co.uk/pictures/IMG_0806.jpg

Field 4 http://www.website.co.uk/pictures/IMG_0807.jpg

Field 5 http://www.website.co.uk/pictures/IMG_0808.jpg

Field 6 http://www.website.co.uk/pictures/IMG_0809.jpg

 

 

I am trying to do a caculation which says take filed 1 and if there is field 2 add this text: <img src" and then "Field 2" and then a " but because there is a " in there that I am trying to add it is causing an error in the calculation, any ideas how to over come this ?

 

Also should I be using an IF statement if I am trying to say Display field 1 and then if there is a field 2 then blah blah blah.

 

The eventual thing I am trying to get to is:

 

http://www.website.co.uk/pictures/IMG_0804.jpg<img src="http://www.website.co.uk/pictures/IMG_0805.jpg"><img src="http://www.website.co.uk/pictures/IMG_0806.jpg"><img src="http://www.website.co.uk/pictures/IMG_0807.jpg"><img src="http://www.website.co.uk/pictures/IMG_0808.jpg"><img src="http://www.website.co.uk/pictures/IMG_0809.jpg">

 

Obviously if there is no field 3 for example it needs to not insert anything apart from 1,2,4,5 and 6

 

 

Any ideas or advice would be greatly appreciated.

 

Kindest regards


Rob

Outcomes