2008 Dec 22 9:14 AM
Hi,
I have store 21 spaces in char21 variable how can i do that.
Thanks
2008 Dec 22 9:16 AM
Hi,
I have store 21 spaces in char21 variable how can i do that.
Thanks
2008 Dec 22 9:16 AM
2008 Dec 22 9:24 AM
Hi,
data g_vairable type char21 value ' '.
-AMR
Edited by: Amresh kumar Panda on Dec 22, 2008 2:55 PM
Edited by: Amresh kumar Panda on Dec 22, 2008 2:56 PM
2008 Dec 22 9:17 AM
Hi ,
Can you explain your specification more clearly?
thanks
siva
2008 Dec 22 9:20 AM
Data : char21(c) type c.
i want to store 21 empty characters (spaces) in char21 variable.
2008 Dec 22 9:24 AM
DATA:lv_space(21) TYPE c,
ur_space(21).
lv_space = ' '.
MOVE: lv_space to ur_space.
Try the above code.
2008 Dec 22 9:24 AM
2008 Dec 22 9:27 AM
Hi Kishan,
it will store one space in variable based on your logic, i want to store 21 spaces.
2008 Dec 22 9:33 AM
How do you wish to use these spaces could you tell?
If you wish to append or concatenate it with some other variable then yu dont have to fill it actually with Spaces.
2008 Dec 22 9:42 AM
I want to use this 21 space if char21 variable is empty, other wise it will store some valu in one conversion program.
2008 Dec 22 9:50 AM
Hi dear,
CHk below logic:
Do 21 times.
Concatenate SPACE W_Char21 into W_Char21.
Enddo.
Regards,
Piyush
2008 Dec 22 10:54 AM
i dont really understand what you are trying to do. But if you do something like this:
concatenate wa_ekpo-ebeln wa_ekpo-ebelp into wa_ekpo-con separated by tab_space.
then you can store 21 character spaces. It does not really fit your requirement. but you can make some changes to fit it in.
pk
2008 Dec 22 11:34 AM
Even if you try to write ayour char21 variable it will leave 21 spaces without moving any spaces in it.
By default it has blanks.
don't know how you intend to check it, but i believe when u declare char21(21) it has blanks in it.
2008 Dec 22 10:04 AM
Hi,
You can use as below.
data: wf_variable type char21.
wf_variable = ` `.
PS: Observe the symbol and send 21 spaces to wf_variable.
Edited by: Deepika Y on Dec 22, 2008 11:06 AM
2008 Dec 22 10:44 AM
Hi,
if you don't have any problem to do it in a static way, then apply this trick.
DATA : space(21) type c.
space = ' '.
write : space, '21 spaces have been written'.
Check this out.
It will solve your problem
2008 Dec 22 10:49 AM
If you want to do this by using code then apply this.
REPORT Y_SPACE.
data : ur_space(21) type c.
DAta : s type c value ' '.
do 21 times.
concatenate s ur_space into ur_space.
enddo.
write : ur_space, 'a'. " See that a is written after 21 spaces.
2008 Dec 22 10:57 AM
Hi,
Declare a constant whose default value is ascii space character by
pressing the key combination of ALT+255 not by hitting spacebar key.
data : co_space_char type c value ' '. "not a normal space it is (ALT+255)
data : char21(21) type c.
do 21 times.
concatenate char21 co_space_char into char21.
endo.
char21 will be having length 21 with spaces.