Cascading Combos vs Treeview control (1 Viewer)

tmyers

Well-known member
Local time
Today, 04:50
Joined
Sep 8, 2020
Messages
1,090
I am still debating on how to structure a spin off to the app I have been working on. Long story short, it is for quoting electrical equipment for apartment/condo style buildings/high-rises. I am going to get very specific on the details prior, so forgive me.

Think about a typical building in an apartment complex. Typically 2-4 stories tall consisting of quite a few units per building. Each of these buildings will have electric metering center. These units typically have a central unit then all of the various branch units that hold the individual electric meters (those giant banks of meters you tend to see on the back of the buildings) attached to them. Example below to give a visual.
Capture.PNG



My initial thought was cascading combos for said meter equipment. The first combo would use the master list to determine that central unit that powers everything. Then based off that selection, would power the next combo with compatible branch devices (the units that actually has the electric meters in them). I was then going to use a datasheet form based off that combo box to determine the electrical breakers and number needed.

However, after reading around and coming across a couple post by MajP, I have started wondering if maybe a tree control would work better for this. What are peoples thoughts on the matter? Would one be better than the other? Would you go a different way?
 

Gasman

Enthusiastic Amateur
Local time
Today, 08:50
Joined
Sep 21, 2011
Messages
14,037
I have never used a Treeview control, but I cannot see much benefit over a cascading combo for your situation.
Combos also appear to be a lot easier to use?, even if you use MajP's treeview

Just my view, not being an expert and all. :(
 

Uncle Gizmo

Nifty Access Guy
Staff member
Local time
Today, 08:50
Joined
Jul 9, 2003
Messages
16,243
it is for quoting electrical equipment for apartment/condo style buildings/high-rises

Is the quote for new build, refurb, maintenance etc...

The essence of my response is that you need to use the system before you can decide how to build it.

Now you'll be saying how can you do that then? Because you haven't built it yet, well the point is, you probably already have system in the nature of spreadsheets or paper forms or maybe just in somebody's head.

It's in using the system yourself, it is in extracting the information you want to use, it is in building the reports you need that will dictate how the structure is and and that might help you decide.

As Paul says, combo boxes are easier to use, and it might well be preferable to build a system with combo boxes and then think about upgrading to a treeview.
 

tmyers

Well-known member
Local time
Today, 04:50
Joined
Sep 8, 2020
Messages
1,090
Is the quote for new build, refurb, maintenance etc...

The essence of my response is that you need to use the system before you can decide how to build it.

Now you'll be saying how can you do that then? Because you haven't built it yet, well the point is, you probably already have system in the nature of spreadsheets or paper forms or maybe just in somebody's head.

It's in using the system yourself, it is in extracting the information you want to use, it is in building the reports you need that will dictate how the structure is and and that might help you decide.

As Paul says, combo boxes are easier to use, and it might well be preferable to build a system with combo boxes and then think about upgrading to a treeview.
It would be for new builds. My initial thought was the combos and I had it all laid out in my head and have started trying to implement it, but it is proving difficult. I know a treeview would be even more complicated, but the image I had of it was very aesthetically pleasing.
 

MajP

You've got your good things, and you've got mine.
Local time
Today, 04:50
Joined
May 21, 2018
Messages
8,463
The big question in my mind is really your datastructure. If this is a network with an unknown amount of levels, then you would likely need a self referencing table. You cannot represent that with combos because the amount of combos is unknown. My initial thought is that this requires a self referencing table and a recursive structure.
 

MajP

You've got your good things, and you've got mine.
Local time
Today, 04:50
Joined
May 21, 2018
Messages
8,463
FYI, if you want a tree I can build you one in a few minutes. It is one query and one line of code.
 

tmyers

Well-known member
Local time
Today, 04:50
Joined
Sep 8, 2020
Messages
1,090
FYI, if you want a tree I can build you one in a few minutes. It is one query and one line of code.
That is entirely up to you. I have been reading on tree views, and first thought was they seemed very...intense lol.
 

tmyers

Well-known member
Local time
Today, 04:50
Joined
Sep 8, 2020
Messages
1,090
Here is what I have been working with. Still very rough and early stage but have at it. I removed all pricing as I obviously can't show that to the world lol.
 

Attachments

  • Example.zip
    183.7 KB · Views: 346

Rene vK

Member
Local time
Today, 09:50
Joined
Mar 3, 2013
Messages
123
When you would use Combo's, a lot of mouseclicks & scrolling is involved. With a tree 2 or 3 clicks can be enough to reach the info you need. I am used to technical project software. These mostly use a tree as start.
From a users standpoint , the tree is a lot easyer to understand.
 

MajP

You've got your good things, and you've got mine.
Local time
Today, 04:50
Joined
May 21, 2018
Messages
8,463
From what I can see you "branch" only has one limb. In other words you do not have a tree as far as I can tell. You just have single level of ranches under the meters. If it was
Meter 1
----- Branch 1
---------SubBranch 1A
----------------SubSubBranch 1A1
---------SubBranch 1 B
-------Branch 2
....
then you would need a recursive structure.
So you could add a tree for aesthetics for viewing and searching, but not needed for representing the data.
 

Users who are viewing this thread

Top Bottom