Error when I try to print a data thats inside a certain node

When i try to print data that are contain inside: groups>disp>phases>parts; the program give me back an error which said that “some expresion have an error”, how can i resolve?



Example (10.5 KB)

Hi Marco,

I took a closer look at your files and tried to use them in the code:

using (ListLabel LL = new ListLabel())
    JsonDataProvider provider = new JsonDataProvider(
                          Path.Combine(Application.StartupPath, "Example dataset.json"), 
                          new JsonDataProviderOptions()

    LL.DataSource = provider;
    LL.AutoProjectFile = Path.Combine(Application.StartupPath, "Example template.lst");

But unfortunately the template Example template.lst does not seem to match the data source Example dataset.json. The template uses the table “Worksheet” with sub-table “groups” etc. and fields from there. But unfortunately this structure does not exist in the JSON itself in that way. It is important that the JSON and the template always exactly match and it looks like someone has changed the JSON structure. Can you check and confirm this?

Has this combination already worked before? If so, which version of List & Label was used and which data provider (source code, options, etc.) was used? This way we can try to better understand the behaviour in detail.

I checked the JSON and it is correct, if the problem in the data is the Worksheet it is normal because this root table is added externally to the JSON file by another program; could you pull the data from the attached files?

Attachements: (16.8 KB)

It is still the same: the data-structure within the template does not match to the used data source (JSON). It is also not easy, if the JSON would be manipulated by another program/prozess before. And if the used source-code (especially the List & abel object, its data provider and its setting etc.) loading that template in the Designer is unknown, modifications are not possible. You need to open the template within your application/implementation and try to fix the isseues within the Designer, if the data modell was changed.

Check your expressions for any syntax or logical errors, proper referencing and data availability. If problem persist then visit support.