Bug 131016 - Libre office base erreur au niveau du compteur d'enregistrement dans le formulaire
Summary: Libre office base erreur au niveau du compteur d'enregistrement dans le fo...
Status: RESOLVED NOTABUG
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Base (show other bugs)
Version:
(earliest affected)
6.3.4.2 release
Hardware: x86-64 (AMD64) Windows (All)
: medium minor
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-02-28 17:22 UTC by flonflonj
Modified: 2020-04-06 15:12 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
copie d'écran avec le probleme (354.10 KB, image/bmp)
2020-02-28 17:30 UTC, flonflonj
Details
copie d'ecran avec le nombre réel d'enregistrement (336.45 KB, image/bmp)
2020-02-28 17:31 UTC, flonflonj
Details

Note You need to log in before you can comment on or make changes to this bug.
Description flonflonj 2020-02-28 17:22:40 UTC
Description:
Lorsqu'il y a un grand nombre d'enregistrement dans un formulaire, le compteur situé en bas à gauche n'indique pas la bonne valeur pour le nombre total d'enregistrements. A l'ouverture du formulaire il indique toujours 41, si l'on va sur l'enregistrement 41 il saute alors à 63 puis ensuite 84 etc... alors que en réalité j'ai 1841 enregistrements

Steps to Reproduce:
1.ouvrir une base
2.ouvrir un formulaire


Actual Results:
le problème apparait alors à condition que le nombre d'enregistrement soit assez important

Expected Results:
Le logiciel devrait indiquer le nombre réel d'enregistrement et ne pas afficher systématiquement 41


Reproducible: Always


User Profile Reset: No



Additional Info:
Veuillez m'excuser mais je ne parle suffisamment bien l’anglais pour pouvoir vous expliquer le problème en Anglais, mais je suis tout à fait disponible pour vous fournir toutes explications complémentaires si nécessaire.
En vous remerciant par avance pour la qualité du travail que l'ensemble des développeurs fournissent et de votre volonté de fournir gratuitement des outils bureautiques de qualité
Comment 1 flonflonj 2020-02-28 17:30:21 UTC
Created attachment 158261 [details]
copie d'écran avec le probleme
Comment 2 flonflonj 2020-02-28 17:31:34 UTC
Created attachment 158262 [details]
copie d'ecran avec le nombre réel d'enregistrement
Comment 3 Robert Großkopf 2020-02-28 18:25:17 UTC
It is a cache-problem. LO doesn't load all the data at once. So it doesn't know how many rows the table will have.

You could switch to last row and then to first row to get the right counter, not only *41.

Many people do this by a macro when loading a form:

SUB MaxRow(oEvent AS OBJECT)
DIM oForm AS OBJECT
oForm = oEvent.Source
oForm.last
oForm.first
END SUB

This macro should be started in the form event "When loading ...".

This macro would be better if you change the content, add rows ...

SUB MaxRow(oEvent AS OBJECT)
DIM oForm AS OBJECT
DIM loMax AS LONG
oForm = oEvent.Source
loPos = oForm.getRow
oForm.last
oForm.absolute(loPos)
END SUB

It reads the rows, which is the current row. It switches to the last row and then back to the row, which has been the row at the start. So you could add data and get the right count of rows.

This macro should be started in the form event "When loading ..." and "After record action ...".

Please report bugs only in English. I have translated your description first with google-translater and hope I understood the problem.
I couldn't find a buggy behavior here, because it shows it couldn't count the whole rows ...
Comment 4 Xisco Faulí 2020-04-06 15:12:37 UTC
Closing as RESOLVED NOTABUG based on comment 3.
@Robert, thanks for the great analysis.