18

I m working on SSRS 2008. i want to display date as 1st January 2011.. but "st" should be in superscipt .. not like "1st".

is there any way to display "st", "nd","rd" and "th" in superscipt without installing any custom font type(other Font Type).

Touseef
  • 414
  • 1
  • 5
  • 17

3 Answers3

40

just copy and paste from the following list:

ABC⁰ ¹ ² ³ ⁴ ⁵ ⁶ ⁷ ⁸ ⁹ ⁺ ⁻ ⁼ ⁽ ⁾ ABC₀ ₁ ₂ ₃ ₄ ₅ ₆ ₇ ₈ ₉ ₊ ₋ ₌ ₍ ₎

ABCᵃ ᵇ ᶜ ᵈ ᵉ ᶠ ᵍ ʰ ⁱ ʲ ᵏ ˡ ᵐ ⁿ ᵒ ᵖ ʳ ˢ ᵗ ᵘ ᵛ ʷ ˣ ʸ ᶻ

ABCᴬ ᴮ ᴰ ᴱ ᴳ ᴴ ᴵ ᴶ ᴷ ᴸ ᴹ ᴺ ᴼ ᴾ ᴿ ᵀ ᵁ ᵂ

ABCₐ ₑ ᵢ ₒ ᵣ ᵤ ᵥ ₓ

ABC½ ¼ ¾ ⅓ ⅔ ⅕ ⅖ ⅗ ⅘ ⅙ ⅚ ⅛ ⅜ ⅝ ⅞ № ℠ ™ © ®

ABC^ ± ¶

S. Mayol
  • 2,565
  • 2
  • 27
  • 34
Mohammad Baygi
  • 604
  • 1
  • 7
  • 13
4

Maybe...

You are limited to what can be done with String.Format. Font size and spacing also refer to the whole text box. So it isn't "native"

However, superscript is unicode so you may be able to to do it with some fancy expression that concatenate characters. I'd suggest custom code.

I haven't tried this, but these articles mention it

gbn
  • 422,506
  • 82
  • 585
  • 676
  • 3
    In 2008, you can set the placeholder format to HTML and use certain HTML tags in your formatting (e.g. `="Some bold text"` works); I don't know if that includes ``, or maybe a `` you could style, though, as I'm only on 2005. – Matt Gibson Jun 13 '11 at 12:53
  • Guyz .. it works for 0-9 only ... i need "st" , "th", "nd" .. i know that superscripts.... i need to know about words that i mentioned .. i dont need 0-9 or n as superscript .. – Touseef Jun 13 '11 at 13:11
  • 1
    @Touseef: then no, you can't do this – gbn Jun 13 '11 at 19:10
1

I am not looking for credit here as above solution has answered it for you but for beginners sake, I use a code function within my report.

So in my SQL say I have Number field, then I add a new field OrdinalNumber:

SELECT ..., Number, 
       CASE WHEN (Number % 100) BETWEEN 10 AND 20 THEN 4
            WHEN (Number % 10) = 1 THEN 1
            WHEN (Number % 10) = 2 THEN 2
            WHEN (Number % 10) = 3 THEN 3
            ELSE 4 END AS OrdinalNumber,
...

Then my code function:

Function OrdinalText(ByVal OrdinalNumber As Integer) As String
    Dim result As String
    Select Case OrdinalNumber
        Case 1
            result = "ˢᵗ"
        Case 2
            result = "ⁿᵈ"
        Case 3
            result = "ʳᵈ"
        Case Else
            result = "ᵗʰ"
    End Select
Return result

End Function

Then in the report textbox I use the expression:

=CStr(Fields!Number.Value) & Code.OrdinalText(Fields!OrdinalNumber.Value)
Glen
  • 802
  • 1
  • 11
  • 27