10-16-2008 2:11 PM
hi guru's,
i am getting the color for my out put text but that is up to the
text only. my requiement is to color the entire line for the particular text ..means till the line end.
cheers,
sravan.
10-16-2008 2:18 PM
Hi,
I believe you are talking about inverse color..i.e Background color....
In yours case you can have a Empty string to be printed to cover the left line space...sp as to get complete line as Inversed colored....
10-16-2008 2:15 PM
Hi,
you can use it like:
write 'Hello world!' color 1. "colors through 1-7
this is for list processing.
hope helps.
deniz.
10-16-2008 2:17 PM
If you use WRITE with COLOR addition it will color only this text which is being outputed.
If you want to use color for entire line use FORMAT statement:
"after this statement everything will be colored until color changes
FORMAT COLOR COL_HEADING.
write: ...
"now if you want to rest color use
FORMAT RESET INTENSIFIED ON.
"here no color will be used
write:....
"and again after this everything will be color
FORMAT COLOR COL_HEADING.
10-16-2008 2:18 PM
Hi,
I believe you are talking about inverse color..i.e Background color....
In yours case you can have a Empty string to be printed to cover the left line space...sp as to get complete line as Inversed colored....
10-16-2008 2:23 PM
i was written the code as shown below
format color 4.
write....
format color off.
but still i am getting up to the output text only.
my requirement is only on foreground not background.
cheers,
kumar.
10-17-2008 5:00 AM
10-17-2008 5:07 AM
Hi Kumar
Try this . Increase the length to change how much it is colored.
Does this solve your issue ?
WRITE (125) 'Hi' COLOR 1.
Regards
10-17-2008 5:15 AM
hi,
we need to write for every statement ...
but i want for bunch of write stements.
instead of adding color for every write statement.. is there any other way to do that... ??
cheers,
kumar.
10-17-2008 5:19 AM
Hi
Try this
FORMAT COLOR COL_HEADING .
WRITE /(125) 'Hi' .
WRITE /(15) 'Hi'.
WRITE /(120) 'Hi'.
FORMAT COLOR OFF.
Regards
10-17-2008 5:27 AM
hi ravi !
thanks for ur response.but i know this .In my Function Module requirement Line Size was dynamic.how can i handle this ?
cheers,
kumar.
10-17-2008 5:32 AM
Hi
When you meant "Line size was dynamic" Did you mean something like this as i did not properly understand your question
DATA : SIZE TYPE I,
COL TYPE I.
DO 10 TIMES.
SIZE = SY-INDEX.
FORMAT COLOR COL_HEADING .
WRITE AT /COL(SIZE) 'Hi' .
FORMAT COLOR OFF.
ENDDO.
Regards
10-17-2008 6:17 AM
hi ravi,
In my case output text also dynamic....
how can achieve this?
cheers,
kumar
10-17-2008 6:22 AM
Hi Kumar,
Did you mean the text in the write stmt is dynamic
DATA : SIZE TYPE I,
COL TYPE I,
TEXT TYPE STRING,
SIZE_CHAR TYPE CHAR05.
DO 10 TIMES.
SIZE = SY-INDEX + 20.
SIZE_CHAR = SY-INDEX.
CONCATENATE 'This is Line' SIZE_CHAR INTO TEXT.
FORMAT COLOR COL_HEADING .
WRITE AT /COL(SIZE) TEXT.
FORMAT COLOR OFF.
ENDDO.
Regards