How to populate list in tree view  dynamically

Hi,
I am new to  Indesign Plugin creation.
I want to create list in tree view dynamically.
I tried wlistboxcomposite sdk sample in indesign cs4.
I have some doubts in this.
1. Can i write my own method in  WLBCmpTreeViewAdapter class because it's implements ListTreeViewAdapter
If it's possible how can i call this method.
2. In this example they populating static string in constructor like this
WLBCmpTreeViewAdapter::WLBCmpTreeViewAdapter(IPMUnknown* boss):ListTreeViewAdapter(boss){
K2Vector<PMString> lists;
for (int32 i = 0; i< 12; i++){PMString name(kWLBCmpItemBaseKey);name.AppendNumber(i+1);name.Translate();lists.push_back(name);}
InterfacePtr<IStringListData> iListData(this, IID_ISTRINGLISTDATA);}
and this list is populating on loading time but my requirement is i have one button "get list" after clicking this button i have to populate the list, how can
i achieve this.
Pls do needful.
Thanks
Arun

The TreeViewAdaptor is responsible for mapping your custom data to the tree view itself.  I almost always start by making it return some fixed number of objects with names "item 1" etc. That way you get the tree view working first.
Then, after you get it laid out and displaying properly, you can worry about using real data.  At that point, you have your adaptor return the actual number of items in your list and each individual item.  Then you can populate your list when you push your button and then invalidate the IControlView of the tree view widget to cause it to redraw.  At that point your adaptor will get called and your data should appear.
Jon
"Expert for hire"

Similar Messages

  • Please Help(How to get RadioButtons in tree View)

    Hi.
    Sub/Requirement: How to implement RadioButtons in tree view with/without using xml file.
    I have a requirement like this i want to display RadioButton in tree view.
    I implemented tree same as which is given in sampleApplications.
    In this sampleApplications they implemted tree by using xml file.
    I also implemented tree by Generating xml file. In this xml file i get the values from the database. I am using <netui:tree > tag.
    Is it possible to implement tree without using xml file. I need to generate tree Dynamically.
    Please any one help me to come out with this solution.

    The issue here is while you are retrieving all the details, you are consistently overwriting them in the request.setAttribute() call before you get to the JSP to display them.
    Do you actually have a class/object called Student?
    That object should have attributes for classes, subjects, teachers (all of which are lists apparently)
    public class Student{
      String name;
      List classes;
      List subjects;
      List teachers;
      // appropriate getter/setter methods
    }Then you load each student, and populate its individual lists.
    That lets you pass the list of students, each student having its own lists for display.
    Hope this helps,
    evnafets

  • How to create list of a View's column names and source

    Using SQL 2005, 2008, and 2012
    How to create list of a View's column names and source. For the following example would like to @Print something like the following.  Does anyone already have some code to do this? I realize there are probably some gotchas, but the views that I am looking
    at to use this follows the code snippet pattern below.
    DBACCT.[Account Number]
    dbo.ConvertDate(DBACDT). [Boarding Date]
    DBXES.DBXES
    CREATE VIEW [dbo].[v_ods_DBAL]
    AS
    SELECT DBACCT AS [Account Number], dbo.ConvertDate(DBACDT) AS [Boarding Date], DBXES
    FROM dbo.ods_DBAL

    The column information can be obtained from INFORMATION_SCHEMA.COLUMNS view using logic like below
    SELECT c.COLUMN_NAME,c.DATA_TYPE
    FROM INFORMATION_SCHEMA.COLUMNS c
    WHERE EXISTS (SELECT 1
    FROM INFORMATION_SCHEMA.TABLES
    WHERE TABLE_NAME = c.TABLE_NAME
    AND TABLE_TYPE='VIEW')
    http://technet.microsoft.com/en-us/library/ms188348.aspx
    Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs

  • How to populate list component via xml file?

    There is a TextArea component that should show the name and
    the description of the item selected in the list component. But I
    dont know how to populate list with external XML and what should be
    the coding in flash as well as what should be written in the XML.
    Please help.

    Here's an xml file listing a couple of brother comedy teams:
    <?xml version="1.0" encoding="UTF-8"?>
    <team>
    <brothers>
    <Marx>
    <name>Groucho</name>
    <name>Chico</name>
    <name>Harpo</name>
    <name>Zeppo</name>
    <name>Gummo</name>
    </Marx>
    <Howard>
    <name>Moe</name>
    <name>Curly</name>
    <name>Shemp</name>
    </Howard>
    </brothers>
    </team>
    Open a new .fla and save it in the same folder as the .xml
    file. Place a List Component on the Stage and name it (in this
    case, "comicTeams_list"). In the first frame write the following
    ActionScript:
    //create XML object and load external xml file
    var broList:XML = new XML();
    broList.ignoreWhite = true;
    broList.onLoad = processList; // this is a function that will
    be written below
    broList.load("populateList.xml");
    function processList(success:Boolean):Void{
    if(success){
    loadList();
    }else{
    trace("Load failure");
    function loadList():Void{
    var broName:String;
    var listEntries =
    broList.firstChild.childNodes[0].childNodes[0].childNodes.length;
    for(var i:Number = 0;i<listEntries;i++){
    broName =
    broList.firstChild.childNodes[0].childNodes[0].childNodes
    .childNodes[0].nodeValue;
    trace(broName);
    comicTeams_list.addItem(broName);
    //to make something happen when you click on a name in the
    List, create a Listener and function
    var broListListener:Object = new Object();
    broListListener.change = someAction; //"someAction" is a
    function to be written shortly
    //add the Listener to the List
    comicTeams_list.addEventListener("change", broListListener);
    function someAction(evtObj:Object):Void{
    var pickedBrother:String = evtObj.target.selectedItem.label;
    //write actions here, referencing pickedBrother variable
    The names of the Marx Brothers will appear in the box.
    This is written in AS2. When you post a question, it's a good
    idea include which version of ActionScript you're using.

  • How to populate list box in module pool program

    How to populate list box in module pool program.
    Please give me reply as soon as posible
    regards,
    Venu.

    hi,
    go thrugh the folling code .
    TABLES sdyn_conn.
    DATA   ok_code TYPE sy-ucomm.
    Global data
    TYPES: BEGIN OF type_carrid,
             carrid type spfli-carrid,
             carrname type scarr-carrname,
           END OF type_carrid.
    DATA itab_carrid TYPE STANDARD TABLE OF type_carrid.
    *& Processing Blocks called by the Runtime Environment                 *
    Event Block START-OF-SELECTION
    START-OF-SELECTION.
      CALL SCREEN 100.
    Dialog Module PBO
    MODULE status_0100 OUTPUT.
      SET PF-STATUS 'SCREEN_100'.
    ENDMODULE.
    Dialog Modules PAI
    MODULE cancel INPUT.
      LEAVE PROGRAM.
    ENDMODULE.
    MODULE user_command_0100 INPUT.
      CASE ok_code.
        WHEN 'SELECTED'.
          MESSAGE i888(sabapdocu) WITH sdyn_conn-carrid.
      ENDCASE.
    ENDMODULE.
    Dialog Module POV
    MODULE create_dropdown_box INPUT.
      SELECT carrid carrname
                    FROM scarr
                    INTO CORRESPONDING FIELDS OF TABLE itab_carrid.
      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
           EXPORTING
                retfield        = 'CARRID'
                value_org       = 'S'
           TABLES
                value_tab       = itab_carrid
           EXCEPTIONS
                parameter_error = 1
                no_values_found = 2
                OTHERS          = 3.
      IF sy-subrc <> 0.
      ENDIF.
    ENDMODULE.
    the following code should be included in flow logic of screen
    process on value-request.
      field scarr-carrname  module create_dropdown_box.
    in module pool select list box.
    hope it is useful.
    regards,
    sreelakshmi.

  • How to set List and Tree Binding Value manually from backing bean?

    Dear All,
    I somehow found this code to work so that I could set a value on my bindings from a managed bean.
      public void setBindingExpressionValue(String expression, Object value)
        FacesContext facesContext = getFacesContext();
        Application app = facesContext.getApplication();
        ExpressionFactory elFactory = app.getExpressionFactory();
        ELContext elContext = facesContext.getELContext();
        ValueExpression valueExp =
          elFactory.createValueExpression(elContext, expression, Object.class);
        valueExp.setValue(elContext, value);
      public class MyBean{
      private String employeeId;
      public void inAmethod(){
           setBindingExpressionValue("#{bindings.employeeId.inputValue}",
                                         getEmployeeId());
      }Now, I am thinking. What if I have a List or Tree Binding in my managed bean then how or what should I send
    to the expression value. Is it a List or Map?
    The first one was easy as it is just a string but how about when dealing with collection?
    JDEV 11g PS4
    Thanks

    Hi,
    a tree binding does not set the value of the tree but determines the selected node. The binding itself represents the collection model that shows the hierarchical tree structure. So your question does not apply to a tree
    Frank

  • How to populate List Item from the table in a form builder

    I want to know how to populate the List Item (pop up menu and combo box) from a table.
    Supposing I have a table Customer(cust_id,cust_name)
    and now I want to populate it in such a manner that I can update the data back to the database and also access the list on the form.

    This is the method i am using to populate a list.
    1- First of all you need to create a non-database list item for customer_name.
    2-create this procedure
    PROCEDURE populate_list_with_query
    --Populates the given list item with the specified query.
    (p_list_item in VARCHAR2
    ,p_query in VARCHAR2)
    IS
    /* Name the record group after the list item (no
    block prefix). */
    cst_rg_name constant VARCHAR2(30) :=
    GET_ITEM_PROPERTY(p_list_item,item_name);
    v_rg_id RECORDGROUP;
    BEGIN
    v_rg_id := FIND_GROUP(cst_rg_name);
    IF ID_NULL(v_rg_id) THEN
    v_rg_id := CREATE_GROUP_FROM_QUERY(cst_rg_name,p_query);
    END IF;
    IF POPULATE_GROUP(v_rg_id) = 0 THEN
    POPULATE_LIST(p_list_item,v_rg_id);
    /* Force display of first list element label
    in the list item. */
    COPY(GET_LIST_ELEMENT_VALUE(p_list_item,1),p_list_item);
    END IF;
    END populate_list_with_query;
    3- Create When-Create-Record on the block level and write this code
    BEGIN
    POPULATE_LIST_WITH_QUERY('bk1.customer_name',
    'SELECT customer_name, to_char(customer_id) FROM customer');
    END;
    In this example, the customer name is the (visible) list label and the customer ID is the (actual) list value
    i hope this will solve your problem ...

  • How to add Icon in Tree View in Forms 6.0 (URGENT..!)

    Hello All,
    I want to add icons in tree view (hierarchical tree) by using
    forms 6.0.
    So pls. help me to find out the solution for the same.
    thanks
    Pradeep
    null

    Pradeep (guest) wrote:
    : Hello All,
    : I want to add icons in tree view (hierarchical tree) by using
    : forms 6.0.
    : So pls. help me to find out the solution for the same.
    : thanks
    : Pradeep
    hello pradeep,
    for adding icons in the tree, u willhave to look closely to the
    data format for the tree.in the data format used for populating
    the tree we are supplying 5 fields. the state of the tree node
    (expanded or collapsed), the depth of the node w.r.t the parent
    node, the node value, the node label(what we see on the tree)
    and the node icon which we want to use. for the node icon we
    have to provide the entire path of the icon file. that's it.
    hope this will solve the problem
    null

  • Urgent, How to Populate List?

    I'm developing an application using Developer 2000 and I'm using a menu to call other forms within the application.
    My problem is that I have a Main-Form with a foreign-key from another table (e.g. CITY_ID is the foreign key and the DESCRIPTION is in the TABLE CITIES).
    In the main-form, I have no problem retreiving the CITIES from the other table, but when I call within the application the form with the CITIES and insert a new row, going back to the main form the new record is not shown.
    In the main-form I'm using the WHEN-NEW-FORM-INSTANCE trigger with the Set_Up_List(CITY_ID, 'RG_CITIES') and EXECUTE_QUERY statements.
    I've tried to use Populate_List but I get FRM error-messages.
    Can anyone HELP ME?

    Hello,
    Friend, It will be better if you write your code to populate list and error messages here, then and then I can guide you.
    Adinath Kamode

  • How to populate transient attribute from view object dynamically

    I have three 4 tables named as "employee,event,event_progress,and checklist progress". i have created a view object using the first three tables . i ahave also created 5 transient variables in to the same view object.when i dragged the view object in to my page as a table i want to populate those transient attribute.
    i have 5 transient attribute which are present as a column value named as chechlist_name in another table "checklist".those all transient attribute also having two sub rows whose data should be populated from the checklist progress table.

    Hi
    Please post your question on this forum, your question belong to this forum.
    JDeveloper and ADF
    Muhammad Nasir

  • How to populate a adf tree programmatically

    Hi,
    I am creating a adf tree (single select) which is the menu of my application.
    Each node of my tree is a command link.
    I am reading the data from a table through a view object (adfbc).
    I want to somehow manipulate my managed bean so that I can display selected rows (permission based) in the adf tree.
    If I am using the condition in the rendered attribute then the nodestamp facet is still rendered and there is a blank row displayed for a node which should not be displayed.
    The other way I was thinking to Iterate the entire tree in my managed bean and remove the nodes which should not be displayed.
    This way the tree is manipulated before it is endered and hence it will not have any blank row in the place of nodes not to be shown.
    Please let me know a few iterating code strip and where(in which method) I should put it in my managed bean to make it work?
    As of now I was putting a tree iterator code in the getMenuTree() method of my managed bean where menuTree is the RichTree object for the tree which I have to render in my UI.
    CollectionModel model = (CollectionModel)this.menuTree.getValue;
    treeBinding = (JUCtrlHierBinding)model.getWrappedData();
    JUCtrlHierNodeBinding root = treeBinding.getRootNodeBinding();
    checkPermission(root);
    List<JUCtrlHierNodeBinding> children = root.getChildren();
    if (children != null)
    for (JUCtrlHierNodeBinding _node : children)
    checkPermission(_node);
    checkPermission - is the method which reads few bindings from the node and decides that this node id eligible for display or not based on user permission.
    But with this code I am getting the node hierarchical structure of the selected node only.
    Thanks in advance

    I thought in this direction... but I cannot access the permission data from VO level as I have to provide this menu interface to multiple projects.
    And the menu I am creating is in a template from where I need to get permission bean of various other projects.
    any other suggestions ?

  • How to populate Lists ?

    I have the following table ADRESSES :
    Create table adresses(
    code varchar2(3) NOT NULL,
    type char(1),
    nom1 ...,
    adresse ...,
    cp ...,
    localite ...,
    primary key (code));
    I want to poulate my list with all the code from the ADRESSES table.
    So, I have created a Record Group 'GROUPE_CODE' with the following SQL statement :
    "select code, code value_code from adresses
    order by code"
    Then I have created the procedure for the update of my List.
    PROCEDURE MAJListeCode IS
    groupeID RecordGroup := Find_Group('GROUPE_CODE');
    listeID Item := Find_Item('Liste_code');
    BEGIN
    IF Populate_Group(groupeID) <> 0 THEN
    MESSAGE ('Impossible de remplir dynamiquement la liste');
    RAISE Form_Trigger_Failure;
    END IF;
    Clear_List(ListeID);
    Populate_List(listeID,groupeID);
    END;
    And finally, I call this procedure in a WHEN NEW FORM INSTANCE trigger.
    But it still doesn't work, I have a FRM-41337 error .. saynig "Cannot Populate the list from group record"
    Could someone help me ?
    Tx in advance,
    Xav.
    null

    Currently using Forms version 6.0.8.21.3 with PL/SQL version 8.0.6.3.0. Is this concoction of products able to populate a list item based on a query based on a table function? I am trying to use the Forms built-in create_group_from_query, with below select-statement, which works fine on SQL Plus (8.0.6.0.0):
    select to_char(pdt_id), sdesc
    from table(get_priceplan_type(2, 47, 1, sysdate))
    In Forms it does not work. An FRM-30351 (No list elements defined for list item) is shown, yet the form is generated "successfully". Any help is much appreciated.
    Kind regards,
    -victorbax-

  • How to populate list of values on screen load

    Hi all,
    I have a list of values based on another field (ANOTHER_FIELD).
    e.g.
    select value d, value r
    from table_name
    where id = :ANOTHER_FIELD;
    ANOTHER_FIELD has default value.
    But when the screen is opened the list of values doesn't get the default value and the list of values is empty.
    Just when submmiting the form, the list of values is populated.
    Please tell me how can I populate the list of values on screen load.
    Thanks!

    Hi,
    So, you have created a computation for ANOTHER_FIELD but the related list still does not get any values? And, the default value for ANOTHER_FIELD is a valid value that can be used to populate the related list?
    Have you set anything for the "Display Null" settings for the related list? Or, is the default value a value will always be in the list?
    Andy

  • How to populate item category tree with UNSPSC codes?

    I have created an application engine to read a UNSPSC code csv file and execute a component interface to load the item categories. I am having a problem updating the tree we use in ePro. Do I need to set up something before I run this? It looks like you can't add nodes if the category doesn't exist and you can't add categories to the tree if the node doesn't exist. We do not have Catalog Management installed.
    Edited by: jbelanger on Aug 4, 2010 8:23 AM

    Dear Friend,
    I am new to the iProcurement functionality of mapping UNSPSC code to Item Category Flex field Segments.
    Please help me how this functionality works.
    Does Oracle provide any standard way to map the codes to flex field.
    Do we need a customization.
    Any useful documentation will be really helpful.
    Thanks in advance
    Pandurang Joshi

  • How to populate data into multi_org view ?

    I do know that a table with ALL is multiorg table and the same table minus ALL is called Multiorg view. I want to know
    1). where exactly we come across the situation in which we use the multi_org view and
    2). how the data is populated into it.
    I do know that the view contains data about a particular ORG. But how ?
    (Assume that we are using the above concept while developing a report and answer accordingly
    I am eagerly searching for the answer.
    your help is appreciated
    Pradeep

    Hi Pradeep,
    Views don't contain any data. Tables do. The multiorg tables (for instance, PO_HEADERS_ALL) contain a column called ORG_ID, which is the id of the operating unit owning each record (a purchase order, in this case). When someone logs in to create a new pucharse order (to continue with the example), he does it selecting a responsibility which have an operating unit (org_id) assigned to it. When the user saves the purchase order, the system will save it automatically with that org_id.
    When the user tries to see purchase orders, he does it through the multiorg view (PO_HEADERS) which is basically a query on PO_HEADERS_ALL restricting by operating unit, i.e:
    PO_HEADERS IS SELECT * FROM PO_HEADERS_ALL WHERE org_id = <Responsibility Org Id>. So, the user will be able to see only the purchase orders assigned tohis operating unit.
    The operating unit gets assigned to a responsibility using profile option 'MO: Operating Unit'.
    This is the idea behind 11i. R12 is using typically a new architecture called MOAC, which is somehow more complicated and allow access to multiple operating units.
    Hope it helps.

Maybe you are looking for

  • Menubar submenu centering problems

    I just downloaded the spry widgets today to use the menubar in a webpage. I need the menu items to be centered but the submenus to be on the left. Unfortunately while it works in Firefox it does not work in IE7. In IE the menu items on top are center

  • Issue on left outer join query in 10G

    Dear Mr./Mrs./Ms. Oracle expertise, The following query structure can function properly in Oracle 9i, but not work in Oracle 10G. Please kindly advise what happened in Oracle 10G? Is it a bug in 10G? If yes, any patch for it? select a.col1, a.col2, a

  • IDVD menu in foreign language?!

    I just opened my iDVD for the first time and saw this: Image: !http://i241.photobucket.com/albums/ff65/MissRowan/iDVD.jpg! Help, please?

  • Outgoing email sits in Drafts since 10.4.6 update

    Hi All Since upgrading to 10.4.6 (and I'm not saying that this is necessarily the cause here), emails I send using Mail.app go to the sent box as normal, but also appear in the Drafts folder a short time after sending. I have been able to confirm in

  • Changing background of selected item in JComboBox when Uneditable

    I need to change the color of the items in a JComboBox list based on the values that change at runtime. I have accomplished this by creating and using a class extended from DefaultListCellRenderer. The combobox is enabled and uneditable. The problem