PC SOFT

FORUMS PROFESSIONNELS
WINDEVWEBDEV et WINDEV Mobile

Accueil → WINDEV Mobile 2024 → TABLE basics and error resolution
TABLE basics and error resolution
Débuté par OGRP, 15 jan. 2018 11:56 - 3 réponses
Membre enregistré
17 messages
Posté le 15 janvier 2018 - 11:56
I am looking into working with TABLES and overall they seem to be very useful and powerful.
I am using Windev Mobile 22 and Android

However I need a little bit of guidance.

A1. Does a TABLE hold an internal index value? If I have element 7 and I sort or filter the table and the element becomes element 1 how can I identify that element 7 is now element 1?

A2. Can you create an additional column on a table with a unique identifier for the row and hide this column to resolve A1?

B. On Android devices, the first column expands to fill the screen size even though the first column has a set value. How can I control this?

C. I have the code in Selecting a row of TABLE. It works in Test mode and generates the apk successfully . However when it runs on a device, an error occurs "The 'FontSize' property does not exist or it is not supported by the looper row elements. How can I increase the font size when I select an row from the table?

nItem is int = TABLE_JOBS
TABLE_JOBS[nItem]..Selected = True
TABLE_JOBS[nItem]..FontSize = 6

Thank you for your help.
Posté le 15 janvier 2018 - 13:55
Hi,

Le 1/15/2018 à 5:56 AM, OGRP a écrit :
I am looking into working with TABLES and overall they seem to be very
useful and powerful.
I am using Windev Mobile 22 and Android

However I need a little bit of guidance.
A1. Does a TABLE hold an internal index value?  If I have element 7 and
I sort or filter the table and the element becomes element 1 how can I
identify that element 7 is now element 1?

No... You need to store your index yourself (use a column set as
invisible for that)

A2. Can you create an additional column on a table with a unique
identifier for the row and hide this column to resolve A1?


Yes, see above. HOWEVER, this applies to table loaded BY PROGRAMMING. a
table linked to a file or query is a completely diferent beast.

B. On Android devices, the first column expands to fill the screen size
even though the first column has a set value.   How can I control this?


There is a setting in the table to choose the column that will expand
based on screen size and anchoring settings.

C. I have the code in Selecting a row of TABLE.  It works in Test mode
and generates the apk successfully .  However when it runs on a device,
an error occurs "The 'FontSize' property does not exist or it is not
supported by the looper row elements.  How can I increase the font size
when I select an row from the table?

nItem is int = TABLE_JOBS
TABLE_JOBS[nItem]..Selected = True
TABLE_JOBS[nItem]..FontSize = 6


Go in the style section of the table description. THere is one entry
there specifically for the selected row. You can choose another font
size there. No code needed.

Thank you for your help.



Best regards

--
Fabrice Harari
International WinDev, WebDev and WinDev mobile Consulting

Ready for you: WXShowroom.com, WXReplication (open source) and now WXEDM
(open source)

More information on http://www.fabriceharari.com
Membre enregistré
17 messages
Posté le 15 janvier 2018 - 15:43
Hi

Additional info. Using Android 5

A1 & A2. - SOLVED. Can you create an additional column on a table with a unique identifier for the row and hide this column to resolve A1?
This was an easy one. Column Description -> Select Colum from Describing A Table Control -> GUI -> Untick Initial Status -> Visible
Therefore a TABLE can have as many columns as required but columns can be hidden and that data then referred to at any time.

C. - SOLVED use the FontSize against table Column Name. e.g. TABLE_JOBS[nSlct].COLL_A..FontSize = 7

I also have a D.

D. The columns do not scroll horizontally on a device although this is switched on.

All help is appreciated.
Message modifié, 15 janvier 2018 - 15:55
Membre enregistré
17 messages
Posté le 15 janvier 2018 - 18:13
Hi

Thank you for your guidance.

There is a setting in the table to choose the column that will expand based on screen size and anchoring settings.
->Which setting is this please. I cannot seem to find it.

Go in the style section of the table description. There is one entry there specifically for the selected row. You can choose another font size there. No code needed.
->On devices this is not increasing the font size. I have just tested previously and again with Android version 6.

The columns do not scroll horizontally on a device although this is switched on.
->For info, the columns are read-only. This may prevent horizontal scrolling?
->I have got around this by having an static control that gets filled in programmatically with all details at the bottom of the page.