Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3786452
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T11:41:07+00:00 2026-05-19T11:41:07+00:00

I have context menu in rich faces tree component(rich:tree).In my tree i had listed

  • 0

I have context menu in rich faces tree component(rich:tree).In my tree i had listed folders and sub folders.By using context menu i can edit datas of the folders and sub folders.I have separate methods for edit folder and sub folders.How can i call this methods in cotnextmenu click action?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T11:41:08+00:00Added an answer on May 19, 2026 at 11:41 am

    You can have 2 different <a4j:jsFunction> for both of your edit folders and subfolders action and call them onclick condition in javascript of contextmenu.

    <rich:menuItem value="Your Context Menu Item" onclick="menuFunction();"></rich:menuItem>
    <a4j:jsFunction name="editFolder" action="#{yourFolder.Edit}"/>
    <a4j:jsFunction name="editSubFolder" action="#{yourSubFolder.Edit}"/>
    

    And script function

    function menuFunction(){
      if(subFolderNodeValue){    //Here subFolderNodeValue is the value of node, you can set it using nodeSelectionListner
         editSubFolder();
      }else{
         editFolder();
      }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a listview with two columns and I'm using a context menu to
I have menu build on Richfaces using rich:menuitem. I need to determine, which menuitem
Is there any way to know the parent/component which initiates context menu? I have
I want to have the context menu of links provide me an option to
I have a context menu with a few items. One of the items has
I have a context menu attached to a panel, that should mirror commands available
I have a context menu. It's bound to some collection and it has a
Do I have any simple way to have context menu items, that aren't highlighted
I have a context menu that is defined as a resource and bound to
I have 1 activity, but would like to have multiple context menu's for different

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.