Assigning Selected Tree Node Value To An Item
Hi guys,
I want to assign selected tree node's value to a page item. This item can be a textbox or a label (display only). How can i do that? I tried to use "Selected Node Page Item" property which is available on Tree Attributes. But I couldn't assign the value without refreshing whole page.
Do you have any idea?
Thanks.
Hi ,
Thank you that was exactly what I was looking for. I couldn't find how to pass database column to javascript as an input parameter. So thanks for your help. I made a couple of correction :
1) I put additional ' characters to ('''||"NAME"||''') this part because my field is varchar.
select case when connect_by_isleaf = 1 then 0
when level = 1 then 1
else -1
end as status,
level,
NAME as title,
null as icon,
"ID" as value,
null as tooltip,
'javascript:setFObjName('''||"NAME"||''')' As link
from "#OWNER#"."TABLE_NAME"
start with "PID" is null
connect by prior "ID" = "PID"
2) In script I have added ' character before and after page item.
function setFObjName(pobjName){
$s('P1_OBJ_NAME', pobjName);
So it works. Thanks tfor your help.
Similar Messages
-
Version: Jdeveloper 11.1.2.1.0
how to get programmatically tree node value.
i have tried but cann't read value from selected node.
please help me.
here is my application creation steps:
1. New Application
2. Fusion Web Application (ADF) Template
3. Create View Object VOTreeMst
Query:
Select Department_Name,Department_Id
From Departments
4. Create View Object VOTreeChd
Query:
Select Last_Name,Employee_Id,Department_Id
From Employees
5. Create View Link VLTreeMstChd
VOTreeMst.DepartmentId=VOTreeChd.DepartmentId
And Add to Application Module
6. Create page page1 in ViewController
New-->Web Tier-->JSF/Facelets-->Page
Selected Document Type JSP XML
7. Drag VOTreeMst1 From Data Controls into page1
and select Tree-->ADF Tree
8. ADD java Code into selection Listener
public void nodeSelect(SelectionEvent selectionEvent) {
//original selection listener set by ADF
String adfSelectionListener = "#{bindings.VOTreeMst1.treeModel.makeCurrent}";
//make sure the default selection listener functionality is preserved.
//you don't need to do this for multi select trees as the ADF binding
//only supports single current row selection
/* START PRESERVER DEFAULT ADF SELECT BEHAVIOR */
FacesContext fctx = FacesContext.getCurrentInstance();
Application application = fctx.getApplication();
ELContext elCtx = fctx.getELContext();
ExpressionFactory exprFactory = application.getExpressionFactory();
MethodExpression me = null;
me = exprFactory.createMethodExpression(elCtx, adfSelectionListener, Object.class,
new Class[] { SelectionEvent.class });
me.invoke(elCtx, new Object[] { selectionEvent });
/* END PRESERVER DEFAULT ADF SELECT BEHAVIOR */
RichTree tree = (RichTree)selectionEvent.getSource();
TreeModel model = (TreeModel)tree.getValue();
//get selected nodes
RowKeySet rowKeySet = selectionEvent.getAddedSet();
Iterator rksIterator = rowKeySet.iterator();
//for single select configurations, thi sonly is called once
while (rksIterator.hasNext()) {
List key = (List)rksIterator.next();
JUCtrlHierBinding treeBinding = null;
CollectionModel collectionModel = (CollectionModel)tree.getValue();
treeBinding = (JUCtrlHierBinding)collectionModel.getWrappedData();
JUCtrlHierNodeBinding nodeBinding = treeBinding.findNodeByKeyPath(key);
Row rw = nodeBinding.getRow();
//print first row attribute. Note that in a tree you have to determine the node
//type if you want to select node attributes by name and not index
String rowType = rw.getStructureDef().getDefName();
if(rowType.equalsIgnoreCase("VOTreeMst")){
System.out.println("This row is a department: " + rw.getAttribute("DepartmentId"));
else if(rowType.equalsIgnoreCase("VOTreeChd")){
System.out.println("This row is an employee: " + rw.getAttribute("EmployeeId"));
else{
System.out.println("Huh ????");
// ... do more usefuls stuff here
9. when i click on first node it is working but i click on second node it is not working
error message::
<LifecycleImpl> <_handleException> ADF_FACES-60098:Faces lifecycle receives unhandled exceptions in phase INVOKE_APPLICATION 5
javax.el.ELException: java.lang.NullPointerException
at com.sun.el.parser.AstValue.invoke(Unknown Source)
at com.sun.el.MethodExpressionImpl.invoke(Unknown Source)
at org.apache.myfaces.trinidad.component.UIXComponentBase.broadcastToMethodExpression(UIXComponentBase.java:1589)
at org.apache.myfaces.trinidad.component.UIXTree.broadcast(UIXTree.java:237)
<RegistrationConfigurator> <handleError> ADF_FACES-60096:Server Exception during PPR, #1
javax.el.ELException: java.lang.NullPointerException
I have also tried using following code but same problem
public void onTreeSelect(SelectionEvent selectionEvent) {
//original selection listener set by ADF
String adfSelectionListener = "#{bindings.VOTreeMst1.treeModel.makeCurrent}";
//make sure the default selection listener functionality is preserved.
//you don't need to do this for multi select trees as the ADF binding
//only supports single current row selection
/* START PRESERVER DEFAULT ADF SELECT BEHAVIOR */
FacesContext fctx = FacesContext.getCurrentInstance();
Application application = fctx.getApplication();
ELContext elCtx = fctx.getELContext();
ExpressionFactory exprFactory = application.getExpressionFactory();
MethodExpression me = null;
me = exprFactory.createMethodExpression(elCtx, adfSelectionListener, Object.class,
new Class[] { SelectionEvent.class });
me.invoke(elCtx, new Object[] { selectionEvent });
/* END PRESERVER DEFAULT ADF SELECT BEHAVIOR */
RichTree tree = (RichTree)selectionEvent.getSource();
TreeModel model = (TreeModel)tree.getValue();
//get selected nodes
RowKeySet rowKeySet = selectionEvent.getAddedSet();
Iterator rksIterator = rowKeySet.iterator();
//for single select configurations, thi sonly is called once
while (rksIterator.hasNext()) {
List key = (List)rksIterator.next();
JUCtrlHierBinding treeBinding = null;
treeBinding = (JUCtrlHierBinding)((CollectionModel)tree.getValue()).getWrappedData();
JUCtrlHierNodeBinding nodeBinding = treeBinding.findNodeByKeyPath(key);
Row rw = nodeBinding.getRow();
//print first row attribute. Note that in a tree you have to determine the node
//type if you want to select node attributes by name and not index
System.out.println("row: " + rw.getAttribute(0));
But
If i create .jspx page From
Web Tier->Jsp->page Then it is working fine
when i create .jspx page From
Web Tier->JSF\Facelets->page Then it is not working
i need to get value from "Web Tier->JSF\Facelets->page"
is there any help please?You should try Franks generic selectionListener http://www.oracle.com/technetwork/developer-tools/adf/learnmore/25-generic-tree-selection-listener-169164.pdf. For help on hoe to get the selected tree node data check http://www.oracle.com/technetwork/developer-tools/adf/learnmore/26-get-selected-tree-node-data-169165.pdf
Timo -
Value of currently selected tree node
Hi there,
I'm new to Apex(4.1.1) and i'm having a little problem.
I got 2 Pages. The frist one consists of a treeregion and a submit button.
The Second one is a Report.
I want to create a workflow, that the user selects a treenode and presses submit. Then he'll be redirected to the reportspage,
wich will show him a report depending on the treenode he selected on the first Page.
Problem:
I have no idea how i can read the value of the selected treenode.
I hope you can help me.
thanks,
FredericHi Frederic,
To obtain the value of the selected tree node, you can make use of the "Selected Page Node Item" attribute on the Tree Attributes page. Just create an item on your page, and set the "Selected Page Node Item" to that new page item. Then populate that item via the LINK parameter of your tree query. For an example, take a look at the following: http://apex.oracle.com/pls/apex/f?p=36648:6 , where I'm setting my page item P6_SELECTED_NODE to the value of the node selected on the first tree i.e. empno. Your report query would need to reference the "Selected Page Node Item", to ensure that it displays information related to the selected tree node.
I hope this helps.
Regards,
Hilary -
Error in Getting Selected Tree node From POPUPMENU
Environment: Forms 9i, 9i AS
The Folowing code is written with in POPUP MENU to get the selected tree node. It always returns 0. The samE code works fine with in any other TRIGGER. Is it Forms BUG?
v_sel_tree := ftree.GET_TREE_SELECTION(v_item,1);Whether or not it is a bug you need a workaround.
How about getting the when-tree-node-selected to set a package variable and look at its value in the pop-up menu code. -
How can I edit the selected tree node immediately?
I have completed a popup menu ,which appeares when I have a mouse rightclicked event
over the selected tree node.when I selected the popup menu item,i can edit the tree node ,but
I feel that the tree celleditor appear slowly ,what should i do? the following is my code:
menuItemRenameNode.addActionListener(new ActionListener()
public void actionPerformed(ActionEvent ae)
renameNode_ActionPerformed(ae);
void renameNode_ActionPerformed(ActionEvent ae){
setEditable(true);
this.getCellEditor().addCellEditorListener(new CellEditorListener(){
public void editingCanceled(ChangeEvent e){
CellEditor cellEditor =(CellEditor)e.getSource();
System.out.println("editing canceled:"+cellEditor.getCellEditorValue().toString());
protected boolean canEditImmediately(EventObject e){
return true;
public void editingStopped(ChangeEvent e){
CellEditor cellEditor =(CellEditor)e.getSource();
System.out.println("editing stopped:"+cellEditor.getCellEditorValue().toString());Please check the suggestions in the thread: https://forums.adobe.com/thread/692020?tstart=0
Regards,
| T. Ravi Kumar -
How to get a Tree Node Value when a Tree is Expanded
My reqiurement is when i Expand a Tree i need the Expanded tree Node Value. For Example Consider Parent as a Root Node of a Tree, and Consider its two Children Child1 and Child2.
When + Parent Expanded
I will Get the Output as --Parent
- Child1
- Child2
so As when i expand the Tree i must Get the String Value Parent.duplicate
How to get a Tree Node Value when a Tree is Expanded -
Af:tree - how do I highlight the selected tree node?
af:tree
I checked the generated CSS file. I found that when a tree node is selected, the related CSS attribute is:
.xj:link{
font-family:Arial,Helvetica,Geneva,sans-serif;
font-size:10pt;
font-weight:normal;
color:#663300
I created a customized CSS attribute, but then all of the links have the customized CSS attributes.
How do I just highlight the selected tree node link?
Thanks,
--Toddtry doing the onclick javascript method
you have to place it on the node element and id must be made dynamic
for this use 'this.id'
by which the current id of the node is passed
and by capturing the id name in a var
use the same for invoking its selected property and make it true
like this
var currentid = this.id;
this.form.currentid.selected = true; -
Highlight the selected Tree Node
Hello Everyone,
Can someone plz tell me how to highlight the selected tree node ?
After selection, user should be able to see which node was last selected.
ThanksHello,
for me it is not really clear what you have done. Sorry!
Because I have problems to paste code, I will describe how you can test that function.
Take the BSP application HTMLB_SAMPLES and copy it to ZHTMLB_SAMPLES. Take page "treeviewSample.htm" and add the following node behind node22:
<htmlb:treeNode id = "node23"
text = "Node 2.2, normal text"
selection="PRIMARYSELECTION">
Perhaps this will show you how it works and help you.
As far as I can see the attribute "selection" can't be set via table.
Best regads
Renald
Edited by: Renald Wittwer on Jan 21, 2010 1:36 PM -
Multi-select Tree Nodes Function
Hello,
I have a tree control built from XML using an HTTPService
call. The tree nodes allow multiple selections. What I would like
to do is, if you click on a parent node to select it, all children
of that tree node would be selected automatically as well, building
the "selectedItems" array.
Does anyone have any idea how I could accomplish this with a
click action function?Do you mean programatically? Because I can retrieve the array
values of multiple items when I manually select them in the
tree, -
Retieve the related childern to the selected Tree Node
Hello all,
From here i got the folowing code,it helps me to retrieve the whole record which is related to the selected node in
WHEN-TREE-NODE-SELECTED Trigger :
declare
rank number := 0;
begin
rank :=
ftree.get_tree_node_property('TREE_BLOCK_TEST.TREE13',
:system.trigger_node, ftree.node_depth);
if rank >= 1 then
GO_BLOCK ('INSP_EQUIPMENT_TYPE');
set_block_property ('INSP_EQUIPMENT_TYPE', default_where,
'EQUIPMENT_TYPE_D='||ftree.get_tree_node_property('TREE_BLOCK_TEST.TREE13',
:system.trigger_node, ftree.node_value));
Execute_Query(No_ValiDATE);
end if;
end; What i want to do is to retieve not only the current record for the selected node but aslo the related childern in the tree to this node.
Could anyboady help me pls. ?!
Regards,
Abdetu..Hi Tony,
what i am trying to do is to display all childern related to the parent 's node selected from the tree that's works fine..
But i want to display the related datablock selected to the child itself the following can't do that can u help me doing it pls...!
DECLARE
rank number := 0;
HTREE$ ITEM := Find_Item('TREE_BLOCK_TEST.TREE13');
BEGIN
IF :SYSTEM.TRIGGER_NODE_SELECTED = 'TRUE' THEN
rank := ftree.get_tree_node_property
('TREE_BLOCK_TEST.TREE13',:system.trigger_node, ftree.node_depth);
if rank = 1 then
set_block_property ('INSP_EQUIPMENT_TYPE', default_where
, 'parent_id='||ftree.get_tree_node_property('TREE_BLOCK_TEST.TREE13',
:system.trigger_node, ftree.node_value));
GO_BLOCK ('INSP_EQUIPMENT_TYPE');
Execute_Query(No_ValiDATE);
elsif rank > 1 then
set_block_property ('INSP_EQUIPMENT_TYPE', default_where
,'EQUIPMENT_TYPE_D='||ftree.get_tree_node_property('TREE_BLOCK_TEST.TREE13',
:system.trigger_node, ftree.node_value));
else
:INSP_EQUIPMENT_TYPE.EQUIPMENT_TYPE :=
FTREE.GET_TREE_NODE_PROPERTY(HTREE$, :SYSTEM.TRIGGER_NODE, FTREE.NODE_LABEL);
END IF;
END IF;
END; -
Select tree node in tree component
hi,
i am developing a web site which has a site map as a tree component, the sitemap is a inserted in a page fragment, users could click tree nodes to go to corresponding pages. also on other pages, i have next and previous buttons which allow users to navigate through pages. the question is how can i update the tree component when users navigate using the next and previous buttons so that the correct tree node is highlighted?
i tried to use the selected property for the tree component, but it does not do anything.
thanks,
leeHi,
Duplicate thread of
http://swforum.sun.com/jive/thread.jspa?threadID=64518
MJ -
Hi Forum,
My Jdeveloper version 11.1.2.0.0
and i am using Fusion Web Application (ADF) Template.
In my .jspx page i have added ADF Tree.
Now i want to get node value from backing bean.
My java code is
public void selectevent(SelectionEvent evt) {
RichTree tree = (RichTree)evt.getSource();
TreeModel model = (TreeModel)tree.getValue();
RowKeySet rowKeySet = evt.getAddedSet();
Object key = rowKeySet.iterator().next();
model.setRowKey(key);
JUCtrlValueBinding nodeBinding = (JUCtrlValueBinding)model.getRowData();
if(model.getDepth()==1){
int empid = (Integer)nodeBinding.getAttribute("EmployeeId");
when i click on second node the following error occured.
<LifecycleImpl> <_handleException> ADF_FACES-60098:Faces lifecycle receives unhandled exceptions in phase INVOKE_APPLICATION 5
javax.el.ELException: java.lang.NullPointerException
at com.sun.el.parser.AstValue.invoke(Unknown Source)
at com.sun.el.MethodExpressionImpl.invoke(Unknown Source)
at org.apache.myfaces.trinidad.component.UIXComponentBase.broadcastToMethodExpression(UIXComponentBase.java:1579)
at org.apache.myfaces.trinidad.component.UIXTree.broadcast(UIXTree.java:237)
at oracle.adf.view.rich.component.rich.data.RichTree.broadcast(RichTree.java:305)
at org.apache.myfaces.trinidad.component.UIXCollection.broadcast(UIXCollection.java:157)
at org.apache.myfaces.trinidad.component.UIXTree.broadcast(UIXTree.java:244)
at oracle.adf.view.rich.component.rich.data.RichTree.broadcast(RichTree.java:305)
at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.broadcastEvents(LifecycleImpl.java:1129)
at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:353)
at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:204)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:312)
at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:173)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.adfinternal.view.faces.webapp.rich.RegistrationFilter.doFilter(RegistrationFilter.java:121)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:468)
at oracle.adfinternal.view.faces.activedata.AdsFilter.doFilter(AdsFilter.java:60)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:468)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:293)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:199)
at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:111)
at java.security.AccessController.doPrivileged(Native Method)
at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:313)
at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:413)
at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:94)
at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:161)
at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:136)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3715)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3681)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)
at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)
at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
Caused by: java.lang.NullPointerException
at tree.view.clsTreeTest.selectevent(clsTreeTest.java:23)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
... 48 more
<RegistrationConfigurator> <handleError> ADF_FACES-60096:Server Exception during PPR, #1
javax.el.ELException: java.lang.NullPointerException
at com.sun.el.parser.AstValue.invoke(Unknown Source)
at com.sun.el.MethodExpressionImpl.invoke(Unknown Source)
at org.apache.myfaces.trinidad.component.UIXComponentBase.broadcastToMethodExpression(UIXComponentBase.java:1579)
at org.apache.myfaces.trinidad.component.UIXTree.broadcast(UIXTree.java:237)
at oracle.adf.view.rich.component.rich.data.RichTree.broadcast(RichTree.java:305)
at org.apache.myfaces.trinidad.component.UIXCollection.broadcast(UIXCollection.java:157)
at org.apache.myfaces.trinidad.component.UIXTree.broadcast(UIXTree.java:244)
at oracle.adf.view.rich.component.rich.data.RichTree.broadcast(RichTree.java:305)
at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.broadcastEvents(LifecycleImpl.java:1129)
at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:353)
at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:204)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:312)
at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:173)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.adfinternal.view.faces.webapp.rich.RegistrationFilter.doFilter(RegistrationFilter.java:121)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:468)
at oracle.adfinternal.view.faces.activedata.AdsFilter.doFilter(AdsFilter.java:60)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:468)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:293)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:199)
at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:111)
at java.security.AccessController.doPrivileged(Native Method)
at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:313)
at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:413)
at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:94)
at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:161)
at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:136)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3715)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3681)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)
at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)
at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
Caused by: java.lang.NullPointerException
at tree.view.clsTreeTest.selectevent(clsTreeTest.java:23)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
... 48 more
Please any solution to get node value programmatically.
ThanksThanks
After applying new code when i click on first node it is working fine but click on second node it produced error like below
<FacesCtrlHierBinding$FacesModel> <makeCurrent> ADFv: No row found for rowKey: [oracle.jbo.Key[], oracle.jbo.Key[]].
<LifecycleImpl> <_handleException> ADF_FACES-60098:Faces lifecycle receives unhandled exceptions in phase INVOKE_APPLICATION 5
javax.el.ELException: java.lang.NullPointerException
at com.sun.el.parser.AstValue.invoke(Unknown Source)
at com.sun.el.MethodExpressionImpl.invoke(Unknown Source)
at org.apache.myfaces.trinidad.component.UIXComponentBase.broadcastToMethodExpression(UIXComponentBase.java:1579)
at org.apache.myfaces.trinidad.component.UIXTree.broadcast(UIXTree.java:237)
at oracle.adf.view.rich.component.rich.data.RichTree.broadcast(RichTree.java:305)
at org.apache.myfaces.trinidad.component.UIXCollection.broadcast(UIXCollection.java:157)
at org.apache.myfaces.trinidad.component.UIXTree.broadcast(UIXTree.java:244)
at oracle.adf.view.rich.component.rich.data.RichTree.broadcast(RichTree.java:305)
at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.broadcastEvents(LifecycleImpl.java:1129)
at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:353)
at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:204)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:312)
at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:173)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.adfinternal.view.faces.webapp.rich.RegistrationFilter.doFilter(RegistrationFilter.java:121)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:468)
at oracle.adfinternal.view.faces.activedata.AdsFilter.doFilter(AdsFilter.java:60)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:468)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:293)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:199)
at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:111)
at java.security.AccessController.doPrivileged(Native Method)
at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:313)
at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:413)
at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:94)
at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:161)
at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:136)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3715)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3681)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)
at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)
at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
Caused by: java.lang.NullPointerException
at tree.view.clsTreeTest.selectevent(clsTreeTest.java:69)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
... 48 more
<RegistrationConfigurator> <handleError> ADF_FACES-60096:Server Exception during PPR, #1
javax.el.ELException: java.lang.NullPointerException
at com.sun.el.parser.AstValue.invoke(Unknown Source)
at com.sun.el.MethodExpressionImpl.invoke(Unknown Source)
at org.apache.myfaces.trinidad.component.UIXComponentBase.broadcastToMethodExpression(UIXComponentBase.java:1579)
at org.apache.myfaces.trinidad.component.UIXTree.broadcast(UIXTree.java:237)
at oracle.adf.view.rich.component.rich.data.RichTree.broadcast(RichTree.java:305)
at org.apache.myfaces.trinidad.component.UIXCollection.broadcast(UIXCollection.java:157)
at org.apache.myfaces.trinidad.component.UIXTree.broadcast(UIXTree.java:244)
at oracle.adf.view.rich.component.rich.data.RichTree.broadcast(RichTree.java:305)
at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.broadcastEvents(LifecycleImpl.java:1129)
at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:353)
at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:204)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:312)
at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:173)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.adfinternal.view.faces.webapp.rich.RegistrationFilter.doFilter(RegistrationFilter.java:121)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:468)
at oracle.adfinternal.view.faces.activedata.AdsFilter.doFilter(AdsFilter.java:60)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:468)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:293)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:199)
at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:111)
at java.security.AccessController.doPrivileged(Native Method)
at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:313)
at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:413)
at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:94)
at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:161)
at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:136)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3715)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3681)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)
at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)
at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
Caused by: java.lang.NullPointerException
at tree.view.clsTreeTest.selectevent(clsTreeTest.java:69)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
... 48 more -
ADF Tree (10.1.3) Programmatically select Tree node
Hi,
i want to pre-select a specific treenode in an af:tree programmatically. I got it nearly working with using a CoreTree-binding in the backing bean using set setFocusRowKey method. After that, the node is selected properly, but when selecting another node in the tree via the UI, the programmatically selected node is not deselected, means in the display is see two selected nodes.
Any ideas ?
Tia,
AndreasHi,
is this the same as
Re: Facing a problem in programmatically setting focus on a node in <af:tre
Frank -
How to select tree node with enter key instead of mouse click
hia i have tree in forms 10g i can get node value when i click mouse on node but i want same with enter key which is not working any idea.
thanxI'm afraid you have hit Bug 4509399
If you have metalink access you should check Note:331369.1
This bug has been around for the 10g R2 10.1.2.0.2 base release, which was propagated from Installing Patch 9.0.4.2 or from 10g R1 base release. You need to apply the latest patch or a one-off fix Patch 4509399
Tony -
Need Help -- How to Change the icon of a selected Tree Node
Hi java gurus,
i am working on Jtree application, and i am adding image icons to the Nodes.
my dought is when i select a node, i want to display that selected node as opened and all other icons should remain closed.
Example:
-- root
|
----child
----child1
----child2
|
----SubChild
----SubChild1
----subchild2
Here if i am selecting Child2 means, only the image icon of that child2 should open the nodes and display the icon , all other icons from root to subchild should remain same as closed.
please some one suggest how i can do it,
Thanks in advance,
Cheers,
MuraliStop crossposting!
http://forum.java.sun.com/thread.jspa?threadID=787916&messageID=4476842#4476842
Maybe you are looking for
-
Some movies no longer play in iTunes
I rip a lot of my DVDs/BR's and put them onto my external drive to play in iTunes and on my Apple TV. I noticed that some of my HD movies will play on my Apple TV, but they won't play in iTunes. I can skip to various scenes and iTunes just stays on t
-
Problems in creating Materialized View from 10g R2 to 11g
Hi, We have two databases in 10g Release 2. These databases are on two different servers and we use Materialized views to replicate data between these servers. We are currently using 64 bit version of oracle 10g release 2 for LINUX. Oracle Database 1
-
Dear All I have a scenerio.My client needs to sell as if sales order is raised for 1 product another allied product has to be picked autoimatically.For e.r If iam creating SO for XXXXX - 10 Nos then YYYY- 10 Nos also to be copied to sales order auto
-
JavaDoc documentation for new BC4J UI classes
Hi All I could not find JavaDoc documentation for new UI packages ( oracle.jbo.uicli.*** ) in JDeveloper 9i RC. Does anybody have an idea where can I find them? Regards, Shota
-
Microsoft Office:Mac v X
Hi there, Im having difficulty installing Microsoft Office v X in my new MacBook Pro. There is no disc icom appearing on the desktop and no installer option. Can anyone help? Many thanks