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

Print Space

Former Member
0 Likes
916

Hi all,

if there a value in the variable then print it else hwo to leave that much blank space.

Regards,

Mohsin

Hi all,

if there a value in the variable then print it else hwo to leave that much blank space.

Regards,

Mohsin

5 REPLIES 5
Read only

peter_ruiz2
Active Contributor
0 Likes
871

hi,

WRITE: /(10) space.

here, (10) specifies the number of characters that will be occupied by space.

regards,

Peter

Read only

Former Member
0 Likes
871

Hi,

if variabl ne ' ' .

print.

endif.

try above logic..

Read only

Former Member
0 Likes
871

hi,

try this.

len = strlen(var).

If var is initial.
do len times.
write: space
enddo.
else.
write: var.
endif.

hope this will help.

Regards

Sumit Agarwal .

Read only

Former Member
0 Likes
871

Hi Mohsin,

Try to print the variables using UNDER stattement. That is print each variable under some heading.

This will automatically print the variable if it has a value in it, otherwise it will leave as many spaces of that variable.

Hope this helps you.

Regards,

Chandra Sekhar

Read only

Former Member
0 Likes
871

if the value is balnk while printing it will take that much blank space.

see the example

data: a(2) type c value 10,

b(2) type c ,

c(3) type c value 100.

write:/ a,b,c.