This content has been marked as final. Show 7 replies
Trees must be in single row, single item blocks.
Your Block: REGION should not contain any other item then TREE1.
For other items create other block.
do what the errormessage sais to you:
create the htree only in a "single-row" block (this is a blockproperty)
don't create additional items in that block
now its not showing that message.... but again its only displaying 2 scrollbars.. and no data
on when-new-form-instance, i have following code.....
-- Find the tree itself.
htree := Find_Item('tree1');
-- Find the record group.
rg_data := FIND_GROUP('RG1');
-- Add the new node at the top level and children.
....no error but and getting the message instatus bar "Data used to populate the tree is invalid" after running the form and just 2 scrollbars...plz hellllllpppppppp
check your query for the record group
query is very simple....
select * from tabname;
The online help isn't much use if you don't already know the form the query should take. Perhaps if it were in the Populating a Tree of Creating a Tree examples there would be less confusion. It appears in the help for the Set_Tree_Property procedure but is not explained there.
The query they use is
'select 1, level, ename, NULL, to_char(empno) ' ||
'from emp ' ||
'connect by prior empno = mgr ' ||
'start with job = ''PRESIDENT'''
The 5 columns you need to select, in this order, are
1) Node State: either 1 or -1, to set the node as expanded or collapsed (not necessarily in that order)
2) Level: the level in the hierarchy
3) Label: the node's label, visible in the tree
4) Icon: the icon to be displayed, or NULL for no icon
5) Value: an arbitrary character value to apply to the node. It isn't visible to the user but you can get the Value at runtime in your code. Use this to store the primary key of the record represented by the node if you want to be able to manipulate that record or query child records when the node is selected.