on ‎2013 Aug 23 4:22 PM
I am trying to add a superscript to a field, I have tried both RTF and HTML formatting but it does not appear to work as it looks like Crystal does not support the relevant HTLM tags
HTML
'<p>'&{psp_GetPortfolioName;1.PortfolioName}&'<sup>1</sup></p>'
RTF
'{\rtf1\ansi\deff0 {\fonttbl {\f0 arial;}} {\pard\fs22'&{psp_GetPortfolioName;1.PortfolioName}&'\super 1\par}'
Both work when viewed either in a browser or word pad.
Are therer any other supported tags which will allow me to display superscripts in Crystal. If not is there any other way of doing this. I do not really want to add a small text box with conditional suppression, but if thats the only solution then I will.
The down side of this is the superscript is static and will float around irrespective of how long field text is. Where as a html or RTF tag would place superscript at end of actual text.
Ian
Request clarification before answering.
Hi Ian,
None of the HTML or RTF subscript/superscript tags are supported by Crystal Reports unfortunately.
An Enhancement Request has already been posted at the Ideas Place.
A workaround other than the Text box one is to use the chrw() function. It accepts an ASCII value and alongwith with a font like 'Arial Unicode MS', it converts it to superscript/subscript.
For e.g: Let's say you want to write CO2. The formula would be:
"CO"&chrw(8322).
After applying the Arial Unicode font to this field, it shows 2 as the Subscript.
You can search for the ASCII chart on google.
-Abhilash
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
If the text you're trying to SuperScript is in a lable (not data), something else you can try in MS Word or another word processing app:
1. Select the font that you're using in your report.
2. Type the letter or string that you want to superscript.
3. Format it as superscript.
4. Copy it and paste into your application.
-Dell
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi
Crystal Reports is not designed to format text objects with subscripts and superscripts. But we can do this in the following way:
1. Create the text object with subscripts or superscripts or both in Microsoft Word.
2. Open the Crystal report.
3. Click Insert > OLE Object.
4. Select the Create from File option. Browse to the location of the document created in step 1.
5. Insert the object into the Crystal report.
Hope this helps to you.
-Sastry
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 5 | |
| 5 | |
| 4 | |
| 4 | |
| 2 | |
| 2 | |
| 2 | |
| 2 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.