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

Smartforms - page protection problem

Former Member
0 Likes
710

Hi,

I have made an invoice form with smartforms. To protect the positions of page breakes, I have made all position nodes in one folder note and set the page protection flag for that folder. Because in tables the page protection option is not working, I have made it all with paragraphs...

This is my problem now:

If the form has more than one page, I have to show the sum of all positions of the first page on the bottom of the page and one the top of the next page. Therefore I have calculated the sum inside the loop of the positions (at the end of the loop).

This is normaly working... But if I have two pages and only <b>ONE</b> position does not fit on the first page, the calculated sum contains the sum of <b>ALL</b> positions, although the last position is shown on the next page!

Any ideas, how I can only calculate the positions that fit on one page <b>FOR REAL</b>?

Thank You very much!

Cheers Arne

5 REPLIES 5
Read only

Former Member
0 Likes
639

Hi,

I encountered a similar problem as ur doing.In dat scenario what i did was that I created a <b>Loop</b> instead of a table and secondly based on the page size please create a style with proper an appropriate tab and use this through out while displaying the line items.

Using a tab will ensure equal spacing everywhere and the data will not overflow from any line and where ur writing a variable place an addition (C) at the end of that variables between the &. This also ensures that the data doesnt overflow and confines to the space.

Hope this will help.

Varun

Read only

0 Likes
639

Hi Varun,

thank You for Your answer!

I have changed the table-node into a loop-node. The page protection ist working fine. But in the end of the loop, I´m calculating the sum. But the problem is, if only one position is shown on the second page, it is adding the amount of this position into my carrying over sum, although it is shown on the next page.

I don´t have an idea to solve that problem, but it´s an urgent issue in my project....

Cheers Arne

Read only

0 Likes
639

Arne,

Is it dat ur showing the sum page wise???

I guess the sum which u will display will be the total for the entire document.

Varun

Read only

0 Likes
639

Yes, I have to show a sum for each page, if there are more than one page. It is, that you can check the sum of all positions on one page.

And the problem is, that the this sum includes also the position on the next page, if there is only one left, which fits not on the first page...

Read only

0 Likes
639

Hi Arne,

Handling the sum page wise is tricky.One thing that u can try is to restrict the number or records displayed per page and then sum them up at the end every page.It should be possible by doing some coding in the loop.

Also this is happening becoz ur doing it in a loop. Iam not sure if we have any system variable for the forms which can tell us the current page number.If we have one we can control this..

Let me try to look for a logic for this.U can try if the above solutions r feasible for our scenario.

Thanks

Varun