cancel
Showing results for 
Search instead for 
Did you mean: 

End of sort - event

0 Kudos

I am developing a new form using smartforms.

In the main window I added a table with different line types. One block shows customer orders. Within the customer the orders get printed. After each order the subtotals of the order and at the end of the customer the totals will be shown.

Everything is working fine so far. I grouped the lines within a folder and set the page protection marker.

But unfortunately the "End of sort" event can not be included into this folder, therefore it can happen, that the subtotals or totals get printed on the next page.

How can I tell the form, that the event should print the totals in the same block as the line items, and if necessary to move the block completely onto the next page?

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi,

Create a text element in that select output options you can find page protection select that checkbox . Count manually the total no of lines that are in the folder and end-of-event. In that text element give that many no of empty lines.

Thanks,

NN.

Former Member
0 Kudos

Hello,

Please do make an note that you cannot page protect by using an folder option or any other option in the table main area, only page protection in the tabel shoould be given in the header and footer.

Now your requirement is to have an page protection at the end of the event.

Create an line type after the event and this line type should be uncheck marked No page protection(this is in the table attribute where you create line type).

Under this line type create an text element and pass all the footer values into one text element with formatting.

This will suffice your requirement.

Former Member
0 Kudos

Rainer,

youre probably right there doesnt seem to be a way to page protect this along with the line items

Can you do this?... capture the value in the event and dispaly it in the footer of the table

You can page protect the footer having it at every page break

0 Kudos

@Raj

As I wrote earlier, I did all this. I need to have the "End of sort" event add to the protected area.

@Nehal

Footer is unfortunately no option. It is for "At page break" and "At end of table". I need to grap the change of a group, either customer or order number.

Thanks

Rainer

Former Member
0 Kudos

maybe its nothing but

what if

you create another row for your subtotaling/summmary

inside the folder which you have page protected.

Copy all the stuff u print in the event into the new row.

At the event set a flag, use this flag to check if the data in this new row should print.

refresh this flag in the row itself after printing.

naah i didnt think so.. lol

0 Kudos

As information: I tried to solve it detecting the change of the group by coding and set the output into the page protected folder.

Nevertheless the page protection does not work even in that case.

I will stop further investigation at this time. Thank for all that tried to help.

Rainer

Former Member
0 Kudos

Am stuck up with the same issue. Just in case if anyone has a solution please post it here.

Vikranth

Former Member
0 Kudos

I found a work around and its working well. Since SFSY-PAGEBREAK isn't available from ECC 6.0 , i used INTSFSY-PAGEBREAK to detect the pagebreak and populate the correct sub totals.

Since INTSFSY is not directly accessible inside the Smartform Program lines, i used a field-symbol to access it and detect the page break.

Hope it helps anyone if future.

Vikranth.

Former Member
0 Kudos

I need to be able to detect when a page break has occured in Smartforms as well. I know that sy-pagebreak is no longer available in ECC 6.0 but would like to try to understan how you used INTSFSY-pagebreak to determine that a page break has occured?

Former Member
0 Kudos

Hi,

1.Call that event in protect and end protect.

2.That solves u r problem

Regards,

Shiva.

0 Kudos

I know PROTECT/END PROTECT in SAPScript but how to apply in smartforms?

Former Member
0 Kudos

Hi,

Right click on the window you will get a option to create a folder.

By using a folder node and checking the 'protect' checkbox, everything in that folder will be page protected.

Create a folder and create all your text elements for a row inside that folder.

Now, switch on the page protection at the folder level in the attributes.

Regards,

Raj.