cancel
Showing results for 
Search instead for 
Did you mean: 

To display vline if main window flows to next page in SAPScript.

Former Member
0 Kudos

Hello,

We are facing issue that we have to put vertical line at the end of page , if main window flows to next page.

In our case, we have payment done for different currencies as well, so that means if for first currency USD we have 20 records then after 16 records page gets break then we want sy-vline to print there and next 4 records in next page, similarily for next currency EUR, then if we have 4 records it gets displayed on one page only, so no vline is required then.

So like this if we have 3 pages to be displayed then on first page it should displayed vline as records gets overflowed.

May be in Script we can have more than 3 pages as well, so at different currency when we have more records then only it should show vline, otherwise not.

Also we have signature window inside main window, so on next page it should not display line after signature.

So please help us for finding the solution to this issue as its really urgent.

Thanks.

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi friend,

So as of now you know that the line count for a page is 16.

So after displaying records in main window just check the sy-index or keep a variable incremental for the loop.

Check whether the variable count is 16 and put a sy-vline. So if we have less number of records or if we have a signature window the vline wont be executed.

This will only be executed when there are 16 records for a page. So for better handling you can use the number of lines per page dynamically. Ie to know the size of lines in the page dynamically.

Else use of end of page command to draw lines at the end of page. But the end of page command should be used inside an if else command.

See the link below for more options in Scripts Link : [Editing Format Actions|http://help.sap.com/saphelp_nw70/helpdata/en/ce/6f0f82ea6311d18e2f0000e83dd9fc/content.htm]

I think this solves your issue. Please revert back to me if you face any issues. I will help you.

Thanks,

Sri Hari

Edited by: srihari.kumar on Jan 31, 2012 4:27 PM