Diese Seite mit anderen teilen ...

Informationen zum Thema:
Forum:
WinDev Forum
Beiträge im Thema:
8
Erster Beitrag:
vor 3 Jahren, 11 Monaten
Letzter Beitrag:
vor 3 Jahren, 11 Monaten
Beteiligte Autoren:
Alexandre Leclerc, JP, Erik Schwarz, ChrisC, Bart VDE

[WD19] - Show empty table cell if zero value

Startbeitrag von JP am 28.07.2014 10:18

Hi All,

I have a table control and some values are zero. How can I not show anything in a table cell if the value is zero? I thought this was done by setting the column "Reset is zero" or perhaps "NULL if empty" checkboxes but this seems to have no effect and the zero values display anyway. Is it possible?

TIA

Antworten:

Hi TIA,

I solved this so far by adding a table column (text type), then converted the respective values to text and displayed them in this column - if zero then format to "".
The original column is hidden and used for Holding the original values.

reset if Zero seems not to work in tables

Erik

von Erik Schwarz - am 28.07.2014 12:17
Hi TIA ;) (and JP)

Tested it in WD16, and checking "Reset if zero" does work here.

Maybe a new feature in V19 ? ;)

Bart

von Bart VDE - am 28.07.2014 12:41
Hi Erik,

You can also use the "On row display" event to set a numeric column or a date column to "" and it will give the same result as you said. It's not required to have a separated column.

Best regards,
Alexandre Leclerc

PS: If I'm not mistaken, this problems occurs when you havve a data table directly linked to a query or table. Then it looks like the check box is not taken account of. But on the row display event you can manually "fix" this. I never thought to send a bug report on that one.

von Alexandre Leclerc - am 28.07.2014 12:41
HI Bart,

You joke but I think you might be right becuase I was so sure that the "Reset if zero" did actually show a blank if the value was zero. This is where my thought came from. But it doesnt work now anymore :/

von JP - am 28.07.2014 12:49
Hi

I can confirm that the 'Reset if zero' option works as advertised in WD19: on a table column which has the type set to Numeric, and the table is linked to the database. Just had occasion to do this recently.

Christopher

von ChrisC - am 29.07.2014 06:07
Hi Alexandre,

thanks for the info, indeed I am using tables directly linked to qeries most of the time.
Will try your approach the next time.


Erik

von Erik Schwarz - am 29.07.2014 06:07
Hi Christopher,

Thank you for confirming this. I know this does not work for a date column - and setting to empty manually is the way we use to fix the problem.

Best regards,
Alexandre Leclerc

von Alexandre Leclerc - am 29.07.2014 12:08
Zur Information:
MySnip.de hat keinen Einfluss auf die Inhalte der Beiträge. Bitte kontaktieren Sie den Administrator des Forums bei Problemen oder Löschforderungen über die Kontaktseite.
Falls die Kontaktaufnahme mit dem Administrator des Forums fehlschlägt, kontaktieren Sie uns bitte über die in unserem Impressum angegebenen Daten.