Page 1 of 1
How to save the tree modified in the program in the DBF database ?
Posted: Mon Jan 13, 2025 9:39 am
by kjedroska
Hi
I'm new here.
I have been using HMG for a short time.
I have a problem with the 'tree' control.
I would like to be able to save data about the tree modified in the program in the DBF database.
Unfortunately I don't know how to do it.
I was hoping that the ParentValue propertie would help me. Unfortunately, it doesn't work properly in version 3.4.4 (32 bit) or 3.6 (64 bit).
To sum up, I want:
- build a tree based on data saved in the dbf database
- save the tree modified in the program to the database
I'm asking you for help.
regards
Krzysztof
Re: How to save the tree modified in the program in the DBF database ?
Posted: Tue Jan 14, 2025 7:57 pm
by mol
Hi! Try to search on the forum. This problem was presented few years ago
Re: How to save the tree modified in the program in the DBF database ?
Posted: Tue Jan 14, 2025 8:01 pm
by miszler.zoltan
Szia, csak néhány kulcsszó: base64, json.
Hi, just a few keywords: base64, json.
Re: How to save the tree modified in the program in the DBF database ?
Posted: Wed Jan 15, 2025 8:37 am
by serge_girard
Krzysztof,
Welcome!
As Marek and Mizler said the forum is full of examples and solutions!
Serge
Re: How to save the tree modified in the program in the DBF database ?
Posted: Thu Jan 16, 2025 10:05 am
by mol
Hi Krzysztof!
To save kategories, I have a dbf with such a fields:
IdKategorii N 6
RodzajKategorii N 1 // określa wydatek/wpływ
IdKategoriiNadrzednej N 6
NazwaKategorii C
Nieaktywny L // used or deleted (hidden for user)
In such a structure you can save your tree
Re: How to save the tree modified in the program in the DBF database ?
Posted: Thu Jan 23, 2025 12:32 pm
by kjedroska
Sorry, guys
I think you misunderstood me.
I have a problem with the 'tree' control.
I would like to use this control to build a tree.
I would then like to save the data from this control to the DBF database so that I can recreate the tree.
I can't find the data defining the parent of the element in this "Tree" control.
Property 'Parent' in "Tree" control doesnt return this data.
Re: How to save the tree modified in the program in the DBF database ?
Posted: Thu Jan 23, 2025 3:15 pm
by edk
Krzysztof, spójrz na ten post:
https://www.hmgforum.com/viewtopic.php?p=65890#p65890, może będzie pomocny. Co prawda struktura drzewa jest zapisywana w json, ale nic nie stoi na przeszkodzie aby zapisać ją w DBF. Spróbuj to zrobić w ramach ćwiczeń z HMG.
Re: How to save the tree modified in the program in the DBF database ?
Posted: Mon Jan 27, 2025 11:54 am
by kjedroska
Hurry !!!
Thanks edk
