How to create a custom DpTreeView

Find and share HowTos to various installations / configurations!
4 posts • Page 1 of 1
GerrieF
Posts:11
Joined: Tue Sep 29, 2020 1:57 am

How to create a custom DpTreeView

Post by GerrieF »

Is there a way to create a DpTreeView with a set filter of DPE's?
Say I want to create a tree with DPT LIKE "mtlib*" and only show DPEs that have _archiving and _address configured.
How can I create this using the DpTreeView instead of using a query builder and a regular Tree? (this takes too long to load)
The DpTree view also has a filter property that the regular tree doesn't have, which would help if the user wants to filter the tree for a specific DPE.
Image

leoknipp
Posts:2928
Joined: Tue Aug 24, 2010 7:28 pm

Re: How to create a custom DpTreeView

Post by leoknipp »

The DP Tree Widget can only be filtered by DPE names. There is no possibility to filter for the configs.
In the standard DP Tree Widget the config information is read when expanding a node. It does not load all the information when opening the panel where it is put into as it would take much too long to load all the information for all DP elements. Therefore filtering for configs does not work.

Best Regards
Leopold Knipp
Senior Support Specialist

gschijndel
Posts:376
Joined: Tue Jan 15, 2019 3:12 pm

Re: How to create a custom DpTreeView

Post by gschijndel »

Perhaps it is possible to create a list of DPEs that have _archiving and _address configs and set the dp filter with it as a comma separated list, like "{dp1.el1,dp1.el2,...}"

leoknipp
Posts:2928
Joined: Tue Aug 24, 2010 7:28 pm

Re: How to create a custom DpTreeView

Post by leoknipp »

To be able to create a list of DP elements you first have to read the complete datamodel to get those elements with an _address and/or _archive config.
As a dpQuery() cannot be used in that a lot of dpGet() calls would be necessary which will possibly create a high load in the system for a longer period of time, depending on the size of the project.
From my point of view it is not a suitable solution.

Best Regards
Leopold Knipp
Senior Support Specialist

4 posts • Page 1 of 1