Hello,
I have :
I would like data in C3 to look like C2 i.e. C3 should have it's data on each line instead of spaces (yes these are spaces since I can get rid of them using 'TRIM').
I was thinking of a formula that replaces 2 or more space with <br>. At the end of the day (whether data in column C are on different lines or separated by spaces) my final results should be like column D.
I have :
Serial | Name | Composition | Data for HTML | |
1 | Destadine Syrup | Each ml contains: Desratadine BP …….. 0.5 In a flavoured syrup base | FORMULA (Thanks to @Fluff) ="<tr><td>"&TEXTJOIN("</td><td>",,SUBSTITUTE(LEFT(A2:C2,LEN(A2:C2)-1),CHAR(10),"<br>"))&"</td></tr" Results =
| |
2 | Terbinafine | Each uncoated tablet contains: Terbinafine Hydrochloride BP eq. to Terbinafine ......................... 250 mg |
I would like data in C3 to look like C2 i.e. C3 should have it's data on each line instead of spaces (yes these are spaces since I can get rid of them using 'TRIM').
I was thinking of a formula that replaces 2 or more space with <br>. At the end of the day (whether data in column C are on different lines or separated by spaces) my final results should be like column D.