Is there a way ...

Please do not use to report errors- use your regional help desk.
Please mark posts as being for RPG or RDMLX (LANSA) developer.
To subscribe by email, display this forum, scroll to the end and select ‘Subscribe Forum’.
Post Reply
stevec
Posts: 138
Joined: Thu Aug 23, 2012 6:45 am

Is there a way ...

Post by stevec »

To tell where I am at currently percentage wise of filling out a page on a device?

For example am I past a viewable page size (maybe 150%) for this device or 25% there or 75% of a page (say portrait). The reason I ask is that I prefer to "fill" the page for a table and have the page stay "in place" and scroll thru the table rows. But if I am already past or near the end of the device page there is no room to scroll or in some cases cannot even get to the remainder of the form (especially on a small device). I am running into this with multiple forms as it becomes more complex with multiple tables. I suppose I could just define the acceptable percentage of the display for each table and calculate the height as a percentage of device pixel height.

Guess I answered this myself lol. Layout_Height('Fit,,' + (#Com_owner.DevicePixelHeight * .15).AsString) seems to work just sizing the percentage (.15 as needed for max)
stevec
Posts: 138
Joined: Thu Aug 23, 2012 6:45 am

Re: Is there a way ...

Post by stevec »

How can I tell how many height pixels I have put out so far? If not then is there a way to tell how many rows are in the DevicePixelHeight?

The reason I need it is so that I can split the remainder left evenly (50% between 2 tables).
tsupartono
Posts: 289
Joined: Wed Apr 18, 2012 10:21 am

Re: Is there a way ...

Post by tsupartono »

Hi Steve,
I think it would be easier if you put the last two tables in a sub-form.
Make the sub-form to have 2 G-Rows, and set the height of both G-Rows to 50% - that should give what you want.

E.g.
LRNG_AssignNumToProp('SubForm.Row%1.Height', '50%');
LRNG_AssignNumToProp('SubForm.Row%2.Height', '50%');

Then you'd put your 2 last tables in the 'SubForm', with the G-Rows set to 1 and 2, respectively.

Just let me know if you need more details on implementation & I will be happy to help.
Post Reply