Focal Point Banner
Community Center Education Summit Technical Support User Groups
Let's Get Social!

Facebook Twitter LinkedIn YouTube
Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [Solved] Multi source Tree Control Help
Go
New
Search
Notify
Tools
Reply
  
[Solved] Multi source Tree Control Help
 Login/Join
 
Silver Member
posted
I'm certain there's a simple solution and missing something fairly obvious here. I am attempting to feed a multi source tree control from a procedure that produces XML. Despite having what I thought would be a hierarchy from two BY fields, I'm instead presented with the Parent repeated for every child.

I'm currently on 8105M. I tried to follow the example presented in the release manual (https://infocenter.informationbuilders.com/wf81rel/index.jsp) , but couldn't achieve what I was seeking.

Procedure: How to Add a Tree Control to an HTML Page Using an Existing Procedure
You can select an existing procedure to add to the tree control in an HTML page. When you select a procedure, it should use fields from the parent/child hierarchy and be set up as follows:

  
TABLE FILE file 
SUM FST.dispfield 
BY ParentUniqueField 
BY UniqueField 
BY datafield 
ON TABLE PCHOLD FORMAT XML 
END


where:

file
Is the name of the data source.

dispfield
Is the field whose values display in the tree control.

ParentUniqueField
Is the field that represents the parent for the parent/child hierarchy (PROPERTY = PARENT_OF).

UniqueField
Is the field that represents the unique IDs for the hierarchy members (PROPERTY=UID).

datafield
Is the field whose values are passed as the parameter value.

On the Canvas I click on the component of the control, went to Properties and set the Number of Levels to (2); on the Parameters section, the control had the corresponding portions of the Levels, selected the first level, went to the Settings tab and applied the first level of the hierarchy, then did the same for the second level.

I wasn't able to find my answer in searching the forums. I'd love to see a simple CAR file example if at all possible. I'm guessing there is a simple nuance I'm missing, please forgive my ignorance on this one. Many thanks for any assistance.

This message has been edited. Last edited by: Mike Williams,


WF Version 8105
 
Posts: 33 | Registered: October 07, 2015Reply With QuoteReport This Post
Guru
posted Hide Post
quote:
it should use fields from the parent/child hierarchy


Does the data source have a parent/child hierarchy? I don't think that the CAR file does.

Of course (as usual) I can find ZERO documentation on how to create a parent/child hierarchy Confused

This message has been edited. Last edited by: Hallway,


Hallway
WF(Prod):8202M
WF(Test):8202M
OS/Platform:Win 10
Outputs:All
 
Posts: 256 | Location: Salt Lake City, UT, USA | Registered: November 18, 2015Reply With QuoteReport This Post
Silver Member
posted Hide Post
quote:
Originally posted by Hallway:
quote:
it should use fields from the parent/child hierarchy


Does the data source have a parent/child hierarchy? I don't think that the CAR file does.

Of course (as usual) I can find ZERO documentation on how to create a parent/child hierarchy Confused


If I recall correctly the CAR Master does.

A Janky example that uses multi-select OR's with the CAR:


-DEFAULT CAR=_FOC_NULL;
TABLE FILE CAR
BY  CAR.ORIGIN.COUNTRY
BY  CAR.COMP.CAR
WHERE ( CAR.ORIGIN.COUNTRY EQ &COUNTRY.(OR(FIND CAR.ORIGIN.COUNTRY IN CAR)).COUNTRY:. ) AND ( CAR.COMP.CAR EQ &CAR.(OR(FIND CAR.COMP.CAR IN CAR)).CAR:. );
ON TABLE SET PAGE-NUM NOLEAD
ON TABLE SET ASNAMES ON
ON TABLE NOTOTAL
ON TABLE PCHOLD FORMAT XML
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
$
ENDSTYLE
END

  


So create a new HTML canvas doc and drag a report then reference that procedure on the HTML canvas, reorder the params with country first, choose the multi source tree so the &CAR is appended to the &Country. Verify the Properties tab is set to 2 levels, then goto params to check settings for the two elements of the hierarchy.


WF Version 8105
 
Posts: 33 | Registered: October 07, 2015Reply With QuoteReport This Post
Guru
posted Hide Post
Check out this link: Procedure: How to Populate a Multi Source Tree Control then click Using Tree Controls then click Populate a Multi Source Tree Control

This will guide you through how to populate the tree using any existing master file.


Hallway
WF(Prod):8202M
WF(Test):8202M
OS/Platform:Win 10
Outputs:All
 
Posts: 256 | Location: Salt Lake City, UT, USA | Registered: November 18, 2015Reply With QuoteReport This Post
Silver Member
posted Hide Post
quote:
Originally posted by Hallway:
Check out this link: Procedure: How to Populate a Multi Source Tree Control then click Using Tree Controls then click Populate a Multi Source Tree Control

This will guide you through how to populate the tree using any existing master file.


Really appreciate it Hallway.


WF Version 8105
 
Posts: 33 | Registered: October 07, 2015Reply With QuoteReport This Post
Guru
posted Hide Post
No problem. I'm glad I was able to find the docs and help out.


Hallway
WF(Prod):8202M
WF(Test):8202M
OS/Platform:Win 10
Outputs:All
 
Posts: 256 | Location: Salt Lake City, UT, USA | Registered: November 18, 2015Reply With QuoteReport This Post
  Powered by Social Strata  
 

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [Solved] Multi source Tree Control Help

Copyright © 1996-2018 Information Builders, leaders in enterprise business intelligence.