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

text colour

Former Member
0 Likes
1,205

hai all,

i want to change the message text colour in abap. how to change the colour.

For eg:

If i give message 'Error" means I want that 'Error' text should come in red colour.

Please help me immediately.

Thanks in advance

Regards

Geetha K

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,150

Hi,

Foll will work

WRITE / : 'No data present for the selected criteria ' COLOR COL_NEGATIVE INTENSIFIED INPUT OFF

HOTSPOT OFF .

COL_NEGATIVE is red

COL_POSITIVE is green

Thanks

Supriya

5 REPLIES 5
Read only

Former Member
0 Likes
1,151

Hi,

Foll will work

WRITE / : 'No data present for the selected criteria ' COLOR COL_NEGATIVE INTENSIFIED INPUT OFF

HOTSPOT OFF .

COL_NEGATIVE is red

COL_POSITIVE is green

Thanks

Supriya

Read only

Former Member
0 Likes
1,150

If you are using message command then automatically error message will come in red colour.

Example

Message 'wrong input' type 'E'. will always come in red colour.

To change the colour in write statement use statemet 'Format Color on' and format colour off.

Example

FORMAT COLOR COL_KEY.

WRITE: text-h01,

FORMAT COLOR OFF.

Read only

Former Member
0 Likes
1,150

Hi Geetha Krishna,

Your requirement is not possible using MESSAGE Statement.

Instead you can go for Module Pools.

There it is possible.

You have to create a screen and set the attributes for that message screen.

Thanks and Best Regards,

Suresh

Read only

Former Member
0 Likes
1,150

WRITE '123456' COLOR COL_NEGATIVE.

Read only

Former Member
0 Likes
1,150

Hi,

If you need to change report text color, you can do this way:

WRITE:/ TEXT-005 COLOR 4 ,SY-SYSID COLOR 3.

Thanks,

Krishna