Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

date format

Former Member
0 Likes
868

can we display the date Nov 14 as 14th november with superscript in abap

is there any func module is there to achieve that

shekhar

7 REPLIES 7
Read only

anversha_s
Active Contributor
0 Likes
835

hi,

DATA: DATE_CHAR(20).
DATA: DATE TYPE SY-DATUM.
DATA: MONTH_NAME LIKE T247-LTX.
DATE = SY-DATUM.

SELECT SINGLE LTX FROM T247
INTO MONTH_NAME
WHERE SPRAS = SY-LANGU
AND MNR = SY-DATUM+4(2).

CONCATENATE SY-DATUM+6(2) MONTH_NAME SY-DATUM(4)
INTO DATE_CHAR SEPARATED BY SPACE.
WRITE: / DATE_CHAR

.

Rgds

Anver

Read only

0 Likes
835

Hi,

the problem i have to display like 14th i.e 'th' should be the superscript of 14.. i don't know if it is possible...

Read only

0 Likes
835

in report i don't think it is possible. but u can do it in sapscript form .that's the one of the reason for using sapscript.

Read only

0 Likes
835

To create superscripts:

Create a new character format : c

In the standard settings set the radio button ON for SUPERSCRIPT.

Then you can assign it to your text as follows:

  • Your text <c>superscripted<>

Where c is the character format.

Example: 21st Feb 2006.

&VBDKR-FKDAT(2)&<c>ST<> &VBDKR-FKDAT+2(8)& ........

c= Charecter format which you creates.

kishan negi

Read only

0 Likes
835

i want to display that in adobe form and not in report...

can you please let me know how u do it in sapscript?

Read only

0 Likes
835

Hi

In scripts you can just create a Character format in that u can select super script / subscript and other options too.

Then where every you want to use can use it as in any scripting language. Like, DD<chatformname>th</>.

But I'm sure it is even easy in Adobe forms.

Regards

Surya.

Read only

Former Member
0 Likes
835

Shekahr,

find this FM if it is useful..

MONTH_NAMES_GET.... Gives you month names in long and short texts..

-Anu