09-17-2009 4:36 PM
Hi,
I have a variable in which some value will be there and that will change. I.e it cannot be fixed.
For Ex g_var has 20 or 30 etc.
I need to display my output starting that that value.
How do I get his. I am sure I need to use field symbols.But am very poor in using field symbols. can some one help me please.
Thanks,
Kiran
09-17-2009 5:31 PM
Hi,
Your question is not clear. Can you elaborate what you are trying to acheive?
Regards,
Vikranth
09-17-2009 6:05 PM
Hi Vikranth, If my variable holds value of 20, I need to display a sy-vline at that 20th position on my list.
Hope this clears. Please let me know, if you need any more info.
Any clues...
Thanks,
Kiran
09-17-2009 6:23 PM
09-17-2009 6:31 PM
Thanks Prakash.
This can be problematic.May be I will have this as my last option.
Any other clues please.
Thanks,
Kiran
09-17-2009 5:43 PM
You can write as ...
loop at final.
write at g_var final-field1.
....
endloop.
09-17-2009 6:45 PM
09-17-2009 7:00 PM
one more option can be:
data: s1 type string.
data : i1 type i value 20.
s1 = sy-vline.
shift s1 by i1 places right.
write : s1.
09-17-2009 7:00 PM
Hi Rob,
Let me explain the complete scenario..
Am using AFTER_LINE_OUTPUT & BEFORE_LINE_OUTPUT to handle my subtotals. So one of my write statements in after_line_output is the grand totals.
WRITE: AT / sy-vline,
2 text-092,
70 g_total_pr,
100 sy-vline.
System automatically puts a ULINE as per the List/line size(which will varry some times) So, if I display sy-vline at 100th place, it doesn't complete the box completely. I get extra horizontal line. So I want to capture the line size and then display the sy-vline at that place.
This is my req. Hope am clear in explaining now.
Please suggest me any clues.
Thanks,
Kiran
09-17-2009 7:09 PM
what will happen if you just remove the '100' before sy-vline? because by removing it, it will just place sy-vline after the line ends...
09-17-2009 7:14 PM
>
> Let me explain the complete scenario...
It would help if you would do this at the beginning. Is there anything else you need to tell us?
Rob
09-17-2009 7:55 PM
YOu can always have something like this to limit the size of the SY-ULINE.
WRITE:/5(50) sy-uline.
09-17-2009 8:06 PM
After your write statment, SY-COLNO has the current column number. Use that to determine where your VLINE should come. Your VLINE position will be SY-COLNO - 1 or SY-COLNO depending on if you want a space in between or not. Remember this will only work in conjunction with WRITE statement.