Hello Michael
Well, difficult to advise because your code is a bit mangled and your process flow is not obvious :)
BayCheck.Initialize runs the procedure "procedure" up to 10 times, which apparently means it adds the same data 10 times into list "Global Checks". However, it never gets past one item of data because apparently MakeBay.Click stores a bunch of data under only one tag. We don't know the tag name because it's a value gathered from a TextBox?
Tag name from TextBox entry is dangerous because:
- It is essentially a variable when it is safer to have constant names for Tags
- There could be Tag Name duplication, resulting in unintentional data overwrite
- Designing in this way suggests large data for which TinyDB might not be suited
You cannot name a Procedure "procedure" - that will potentially crash the app. Give it a name that describes it's purpose.
Give Components meaningful names but always retain the component type name e.g. Label_PickedValue_Scn1, Button_CalcTotal_Scn1.
Is your while test is an attempt to delay loading of the ListViews until the procedure has completed?
To help more, we need to know:
- What your data is
- Where it comes from
- How often does it update
- What you want to do with it