Html in htmlB Tree Title

We're moving our portal apps from ep6.20 onto Netweaver SP12, and I've found several htmlB components that no longer seem to accept Html in various "text" settings (Tree Title and TableView Header notably)--the HtmlB component seems to always encode the text.
Does anyone know of a way to include Html in a Tree Title? 
TableView provides a HeaderRenderer, which is an acceptable workaround for that component.  Are there any known workarounds for Tree Title?
Thanks,
Curt

Hi Prakash
That's sort of the approach I've taken for now.  I'm currently writing html as the content for other nodes, so this was the solution that came immediately to mind.  However, it appears that even if you set
root.setShowExpander(false);
, the expander always shows.  Goal was to have non-expandable "title" for tree.  May need to consider wrapping the tree in a Group.
Thanks for the suggestion,
Curt

Similar Messages

  • How to change color of htmlb tree...

    Hi, I am analyzing the htmlb tree tag, and wondering how I can change the color of each row, or change the color of the whole tree white?  I know about the style editor, but I'm looking for a way code-wise to make this change.  I have pasted code below for your reference.  Any help or styling tips would be very appreciated!
    Thank you so much! Baggett
    <b>   <hbj:tree id="S_Tree" title="e-enviroment" tooltip="enviroment of my computer">
               <hbj:treeNode id="e_root" text="Desk" isOpen="true" tooltip="My desk">
                   <hbj:treeNode id="e_comp" text="Computer" isOpen="true">
                        <hbj:treeNode id="e_comp_fl" text="Floppy"/>           
                      </hbj:treeNode>
                   <hbj:treeNode id="e_net" text="Network" isOpen="true" tooltip="Company network">
                        <hbj:treeNode id="n_lan" text="LAN" tooltip="Local Area Network"/>                 
                    </hbj:treeNode>
               </hbj:treeNode>
       </hbj:tree></b>

    What rajesh suggested won't work.
    <hbj:tree id="S_Tree" title="e-enviroment" tooltip="enviroment of my computer">
    <%
      S_tree.setEncode(false);
      S_tree.setText("<span style=background-color: #FFFF00>e-enviroment</span>");
    %>
    <hbj:treeNode id="e_root" text="Desk" isOpen="true" tooltip="My desk">
    <%
      e_root.setEncode(false);
      e_root.setText("<span style=background-color: #FFFF00>Desk</span>");
    %>
    <hbj:treeNode id="e_comp" text="Computer" isOpen="true">
    <%
      e_comp.setEncode(false);
      e_comp.setText("<span style=background-color: #FFFF00>Computer</span>");
    %>
    <hbj:treeNode id="e_comp_fl" text="Floppy"/>
    </hbj:treeNode>
    <hbj:treeNode id="e_net" text="Network" isOpen="true" tooltip="Company network">
    <%
      e_net.setEncode(false);
      e_net.setText("<span style=background-color: #FFFF00>Network</span>");
    %>
    <hbj:treeNode id="n_lan" text="LAN" tooltip="Local Area Network"/>
    </hbj:treeNode>
    </hbj:treeNode>
    </hbj:tree>
    Message was edited by: Prakash  Singh

  • Htmlb:tree differentiate between nodeclick and tree node expander click

    Hi,
    how can i differentiate between nodeclick and tree node expander (to get to its children) click in my event processing in htmlb:tree element.
    <u><b>What i am trying to achieve?</b></u>
    Onload just load root node and its immediate children.
    On node expand get the children of the current node and modify htmlb:tree table2 with additional node inofs.
    on node click  call some client function.
    But my issue is that i am not able to differentiate between node expander click and node click in my event handling. Any help on this is appreciated.
    (I am not using MVC)
    Thanks in advance.
    Regards
    Raja
    Message was edited by: Durairaj Athavan Raja

    After reading your weblog I think I understand better. I did some testing with my example.  I am using the toggle = "true", so that the page returns to the server each time an expander is selected.
    <htmlb:tree id          = "myTree1"
                  height      = "75%"
                  toggle      = "true"
                  title       = "<b><otr>EQI Reporting Tree</otr></b>"
                  width       = "90%"
                  onTreeClick = "myTreeClick"
                  table       = "<%= application->selection_model->itview                             %>" >
      </htmlb:tree>
    However I have not added any coding in my event handler to respond to the expander event.  I only respond to myTreeClick (which loads some data for the given selection).  The BSP tree element itself must be doing the hard work for me. 
      if event_id cs 'tr_myTree1'.
        data: tree_event type ref to cl_htmlb_event_tree.
        tree_event ?= htmlb_event.
        if tree_event->server_event = 'myTreeClick'.
          clear appl->message1.
          appl->selection_model->get_chart_data( appl = appl
                                                 node = tree_event->node ).
        endif.
      endif.
    I pass my entire tree defintion to the element.  It appears that it only sends visible nodes to be rendered. When the expander is selected, I don't have to do anything, the tree re-renders with only the newly visible rows. 
    I tested and turned off the toggle (toggle = "false") and my page took forever to load because it was sending all the nodes to the frontend on the first load.

  • RestoreViewState  with HTMLB-TREES/TREENODES

    Hello,
    we want to achieve that our dynamic tree will
    be built up in the state it was before we jumped onto another page. When navigating backwards, the tree
    does not remember any more it treenodes properties.
    Just the root is displayed, not any more the information which node was open and which not.
    Also restoreViewState  = "TRUE" did not help.
    Any ideas ?
    Thanks.

    Here is a complete (yet simplistic) example that proves that the serialization idea works.
    Stateless Application
    Page One called tree.htm
    Page Attributes (Auto Flag is NOT set)
    h1_isopen     TYPE     STRING
    h2_isopen     TYPE     STRING
    view_state     TYPE     SHSVALTAB
    OnInitialization
    * event handler for data retrieval
    DATA: istream TYPE string,
             xslt_err TYPE REF TO cx_xslt_exception.
    **** Read Server cookie
    CALL METHOD cl_bsp_server_side_cookie=>get_server_cookie
       EXPORTING
         name                  = 'view_state'
         application_name      = runtime->application_name
         application_namespace = runtime->application_namespace
         username              = sy-uname
         session_id            = runtime->session_id
         data_name             = 'view_state'
       CHANGING
         data_value            = istream.
    **** deserialize the Class
    IF istream IS NOT INITIAL.
       TRY.
           CALL TRANSFORMATION id
           SOURCE XML istream
           RESULT view_state = view_state.
         CATCH cx_xslt_exception INTO xslt_err.
       ENDTRY.
    ENDIF.
    CHECK view_state IS NOT INITIAL.
    FIELD-SYMBOLS: <wa_state> LIKE LINE OF view_state.
    LOOP AT view_state ASSIGNING <wa_state>.
       IF <wa_state>-key CS 'Header1'.
         IF <wa_state>-value = 'O'.
           h1_isopen = 'TRUE'.
         ENDIF.
       ENDIF.
       IF <wa_state>-key CS 'Header2'.
         IF <wa_state>-value = 'O'.
           h2_isopen = 'TRUE'.
         ENDIF.
       ENDIF.
    ENDLOOP.
    OnInputProcessing
    * event handler for checking and processing user input and
    * for defining navigation
    DATA: fields TYPE tihttpnvp.
    request->get_form_fields( CHANGING fields = fields ).
    FIELD-SYMBOLS: <wa_field> LIKE LINE OF fields,
                   <wa_state> LIKE LINE OF view_state.
    LOOP AT fields ASSIGNING <wa_field>.
      IF <wa_field>-name CS 'test'. "My Tree ID
        APPEND INITIAL LINE TO view_state ASSIGNING <wa_state>.
        <wa_state>-key   = <wa_field>-name.
        <wa_state>-value = <wa_field>-value.
      ENDIF.
    ENDLOOP.
    DATA: ostream TYPE string,
            xslt_err TYPE REF TO cx_xslt_exception.
    ***** serialize model class
    TRY.
        CALL TRANSFORMATION id
        SOURCE view_state = view_state
        RESULT XML ostream.
    ****Write cookie it into the Server Cookie
        cl_bsp_server_side_cookie=>set_server_cookie( name = 'view_state'
          application_name = runtime->application_name
          application_namespace = runtime->application_namespace
          username = sy-uname
          session_id = runtime->session_id
          data_name = 'view_state'
          data_value = ostream
          expiry_time_rel = '1200' ).
      CATCH cx_xslt_exception INTO xslt_err.
    ENDTRY.
    navigation->goto_page( 'Navigate.htm' ).
    Layout of tree.htm
    <%@page language="abap" %>
    <%@extension name="htmlb" prefix="htmlb" %>
    <htmlb:content design="design2003" >
      <htmlb:page title=" " >
        <htmlb:form>
          <htmlb:tree id               = "test"
                      restoreViewState = "TRUE" >
            <htmlb:treeNode id     = "Header1"
                            text   = "Header1"
                            isOpen = "<%= h1_isopen %>" >
              <htmlb:treeNode id     = "Header2"
                              text   = "Header2"
                              isOpen = "<%= h2_isopen %>" >
                <htmlb:treeNode id   = "Item1"
                                text = "Item1" />
                <htmlb:treeNode id   = "Item2"
                                text = "Item2" />
              </htmlb:treeNode>
              <htmlb:treeNode id   = "Item3"
                              text = "Item3" />
              <htmlb:button text    = "test"
                            onClick = "TEST" />
            </htmlb:treeNode>
          </htmlb:tree>
        </htmlb:form>
      </htmlb:page>
    </htmlb:content>
    Second Page Navigate.htm (Just a dummy page to simulate Navigation)
    OnInputProcessing
    * event handler for checking and processing user input and
    * for defining navigation
    navigation->goto_page( 'tree.htm' ).
    Layout for Navigate.htm
    <%@page language="abap"%>
    <%@extension name="htmlb" prefix="htmlb"%>
    <htmlb:content design="design2003">
      <htmlb:page title = " ">
        <htmlb:form>
          <htmlb:textView     text          = "Hello World!"
                              design        = "EMPHASIZED" />
          <htmlb:button       text          = "Press Me"
                              onClick       = "myClickHandler" />
        </htmlb:form>
      </htmlb:page>
    </htmlb:content>

  • Bsp htmlb:tree

    Hi,
    I created a BSP application with dynamic htmlb:tree using TVIEW2. Everything works fine BUT... when I navigate to another page and I return to the page containing the tree-object, my tree is no longer displayed, although the internal table TVIEW2 is properly filled. Anyone experienced this problem also??? Possible solution?

    Layout:
        <myhtmlb:gridLayoutCell columnIndex = "1"
                                rowIndex    = "1" >
          <%-- Overview tree --%>
          <myxhtmlb:overflowContainer height = "495"
                                      width  = "350"
                                      mode   = "SCROLL" >
            <myhtmlb:tree id               = "TREE_PROP"
                          onTreeClick      = "OnInputProcessing"
                          restoreViewState = "TRUE"
                          height           = "495"
                          width            = "350"
                          table2           = "<%= i_tree %>"
                          title            = "Personnel Overview" />
          </myxhtmlb:overflowContainer>
        </myhtmlb:gridLayoutCell>
    internal table i_tree is filled in OnInitialization event. The table is proporly filled.

  • Htmlb:group - title instead of htmlb:groupHeader

    When you use a htmlb:Group, there are two ways to add text to the group header. You can use
      <htmlb:group title="hello">
    or
      <htmlb:group>
        <htmlb:groupHeader>
          <htmlb:textView text="hello" />
        </htmlb:groupHeader>
    I'd like to change from the first variant to the second, because I want to add a link to the group-header.
    Unfortunately, the header is a little higher if you use the secont variant. Is there a way to overcome this problem? Can I make the groupHeader as small as the title?
    Best regards,
    Daniel

    There is always something you can do about it
    One way would be to use a <htmlb:findAndReplace> element around your troubling elements and simply replace the HTML code you want to change.
    Of course you would have to check that every time you do some SP upgrade, so no very elegant ...
    (but it's a way)
    Max

  • How to: display the pcd in a htmlb tree object?

    Hello @ all,
    I'm currently trying to implement the contents of the PCD into a htmlb tree structure for an application of mine.
    while the tree creation isn't a problem, i have no idea where to start on how to read/parse the pcd structure.
    the reason for me trying to stuff the pcd into a tree is to achieve an easier to handle navigation.
    so of anybody could point me in the right direction as how to get access to the pcd porperly and how to get the complete pcd structure (folder, iviews, everything) so that i could include it in the tree, i would be really thankful.
    cheers,
    jürgen

    Hi Jürgen,
    See http://help.sap.com/saphelp_nw04/helpdata/en/44/6aaf92f5a23672e10000000a114a6b/frameset.htm
    Only Worksets and Roles are not described, anyhow, doing a bit research via decompiling or just by searching on SDN will bring you the needed extra info; just as an example for roles access: https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/6112ecb7-0a01-0010-ef90-941c70c9e401
    Hope it helps
    Detlev

  • Htmlb:tree: Expand All

    I tried to implement an "Expand All" functionality for my htmlb:tree. Strangely, I can change the nodes in the tree table, but they are still displayed as closed on the screen.
    LOOP AT me->t_tree ASSIGNING <fs> WHERE status = cl_htmlb_treenode=>c_treenode_closed
                                             OR toggle = cl_bdv_co=>c_true.
          <fs>-status = cl_htmlb_treenode=>c_treenode_open.
          <fs>-toggle = cl_bdv_co=>c_false.
    ENDLOOP.
    Why is this? Has this anything to do with the TOGGLE functionality of the tree (which loads certain subtrees with a new server event) ?

    >Has anybody an explanation for this
    Delta-Handling is half Black Magic Voodoo anyway.  I assume that the DH server side cache doesn't see any change in those fields (since you have removed them) and therefore doesn't resend them to the client (it only sends changed values).
    The Client side cache still has the old values in memory and didn't get an update from the server.  Therefore it still renders the old values.
    You might try placing a delta handler block around your tree coding:
    <bsp:deltaHandlerBlock id="protectionR2" >
        <htmlb:tree ... />
    </bsp:deltaHandlerBlock>
    You can try playing with the attributes of the DHBlock.  Try attribute clientCacheClear when you want force a change to the tree.

  • Htmlb:tree node count limitation

    Hi Experts,
    I have a problem with htmlb:tree. Rendering up to 60 nodes will works well, if my tree has more than 60-65  nodes and I klick any link or the tree itself, after rendering has been finished, the Browser will get stuck and keep searching forever. SAP recommends to use htmlb:tree for trees with 30-50 nodes. Some suggestion was to load the node using AJAX. Are there some other ideas?
    Many thanks for help!

    check out this weblog
    [BSP/How-To: Build performance-efficient dynamic htmlb:tree|BSP/How-To: Build performance-efficient dynamic htmlb:tree]
    Raja

  • Create columns for HTMLB:TREE

    Hi All,
    In our appplication we are are using <htmlb:tree />. Using CL_BSP_BEE_TABLE we were able to show checkbox inside the tree node. CL_BSP_BEE_TABLE was of great help.
    Now we need columns in tree. Is there a way to create columns using BEE?
    Thanks and regards,
    Bindiya

    I am using a tree with about 2500 nodes and and around 5000 final children (leaves)  and we dont face any problem using the approach i have explained in my weblog.
    i guess the best approach would be to just do it and check whether you are having problem.
    <i>Do you know of any good alternatives to the htmlb:tree?</i>
    there are other javascrip/dhtml trees but you will still face the same kind of issues.
    Regards
    Raja

  • Complied chm file displays 'HTML help' on the title bar instead of the window name

    Complied chm file displays 'HTML help' on the title bar instead of the window name.
    I tried several ways like:
    1. Changed File>Project settings name and also set the language to English (US).
    2. Checked the Title name in .hhp file
    3. Used the window while compling.
    4. Robohelp language settings.
    5. Also uninstalled and reinstalled robophelp.
    But nothing helped
    The title name is displayed correctly if the same project is compiled on another machine.

    When the code in the HHP and the regional settings on a PC match, the correct title is displayed. Or other way around is also true the help title is displayed in the language specified in the help project IF (and only if) the regional settings of the PC match that language. Otherwise, "HTML Help" is displayed.
    Hope this help.
    Thanks and Regards,
    Rahul Karn

  • Htmlb:tree

    Hi,
    I created a BSP application with dynamic htmlb:tree using TVIEW2.  Everything works fine BUT...  when I navigate to another page and I return to the page containing the tree-object, my tree is no longer displayed, although the internal table TVIEW2 is properly filled.  Anyone experienced this problem also???  Possible solution?

    What exactly happens?
    Is nothing at all displayed?
    Can you post some coding?

  • HtmlB tree context menu

    Hi guys,
    do you if it is possible to add a context menu on an htmlb tree?
    regards,
    Marc

    Hi Marc,
         You can use the hover menu which works as a context menu.
    The below code is just a sample.
    TreeNode name1 = new TreeNode(strid, strtext, name);
    //you to have build the hovermenu
    HoverMenu menu = new HoverMenu("test");
    name1.setHoverMenu(menu);

  • Movies with iTunes Extras show only HTML code and not title screen when double clicked.

    I only noticed this after some iTunes updates.  Any movies that have iTunes Extras donot show the "Title Screen" when double clicked.  They only show HTML script.  I can still watch the movies, and can access the extras by going to the folder they are in, but thats a pain.  I have purchased other movies with extras since encountering the problem and have the same issue.  I run windows Vista on a 32-bit system. I have all updated drivers.  I have searched the web for an answer but couldnt find anything.  It is prob something insanely easy.  Any help would be appriciated.
    Example of text that appears when double clicking:
    <!doctype html>
    <html>
    <head>
         <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
         <meta name="hdtv-fullscreen" content="true" />     
         <meta name="hdtv-cursor-off" content="true" />          
         <title>Paul (Unrated) [2011]</title>          
         <!--      TuneKit      -->   
      <script type="text/javascript" src="TuneKit/src/TuneKit.js" charset="utf-8"></script>          
         <!--      Styles      -->     
         <link rel="stylesheet" href="css/shared.css" type="text/css" media="screen" />     
         <link rel="stylesheet" href="css/home.css" type="text/css" media="screen" />     
         <link rel="stylesheet" href="css/chapters.css" type="text/css" media="screen" />     
         <link rel="stylesheet" href="css/features.css" type="text/css" media="screen" />     
         <link rel="stylesheet" href="css/more.css" type="text/css" media="screen" />          
         <!--      Controllers      -->     
         <script type="text/javascript" src="controllers/data.js" charset="utf-8"></script>     
         <script type="text/javascript" src="controllers/home.js" charset="utf-8"></script>     
         <script type="text/javascript" src="controllers/chapters.js" charset="utf-8"></script>     
         <script type="text/javascript" src="controllers/features.js" charset="utf-8"></script>     
         <script type="text/javascript" src="controllers/more.js" charset="utf-8"></script>
    </head>
    <body>
         <div id="bleed">          
              <div id="navigation">             
                   <img id="pic0" class="picBLANK" src="images/home/Paul_mm_background_01.jpg"/>            
              <img id="pic1" class="picBLANK" src="images/home/Paul_mm_background_01.jpg"/>             
                   <img id="pic2" class="picBLANK" src="images/home/Paul_mm_background_02.jpg"/>            
              <img id="pic3" class="picBLANK" src="images/home/Paul_mm_background_03.jpg" />            
              <img id="pic4" class="picBLANK" src="images/home/Paul_mm_background_04.jpg" />            
              <img id="pic5" class="picBLANK" src="images/home/Paul_mm_background_05.jpg" />            
              <img id="pic6" class="picBLANK" src="images/home/Paul_mm_background_06.jpg" />            
              <img id="pic7" class="picBLANK" src="images/home/Paul_mm_background_07.jpg" />            
              <img id="pic8" class="picBLANK" src="images/home/Paul_mm_background_08.jpg" />            
              <img id="pic9" class="picBLANK" src="images/home/Paul_mm_background_09.jpg" />            
              <img id="pic10" class="picBLANK" src="images/home/Paul_mm_background_01.jpg" />             
                   <div id="vid" class="vid_bg">               
                        </div>          
              </div>     
         </div>
    </body>
    </html>

    The fix from this other post worked for me.
    https://discussions.apple.com/message/17691332#17691332
    FIX:
    Go into "Get Info" and set the Album name to the name of the movie for both the movie and the "Extra".  This will fix it.

  • Wrapping in htmlb:tray - title ?

    I guess it isn't possible to do an automatical wrapping in the header of an htmlb:tray, right?
    my code looks like this and i don't know in advance how long the title is..
    <htmlb:tray id="t1" title="<%=controller->get_header_description( )%>"
    width = "<%= lv_width %>">
    </htmlb:tray>

    HEre's a method I've copied into a few things from the SAP <i>DSWP_CREATE_MSG</i> BSP Application that comes with Solution Manager class name is <i>CL_DSMOP_BSP_MSG_CTRL</i>.
    Format:
    CALL METHOD me->word_wrap
        EXPORTING
          input_string = m_msg_long_text
        IMPORTING
          output_table = lt_text_table.
    method WORD_WRAP .
    DATA: line_length TYPE i,            " Length of input string
    *      field_length TYPE i,           " Length of line in table
          lf_iPos  type i,
          lf_iTmp  type i,
          lf_sTmp  type string,
          lf_cChar type char1.
    data: lf_Lines   type i,
    *      component  type abap_compdescr,
    *      LT_HTML    type dswpw3html,
          lf_sString type string.
      lf_sString = input_string.
    * Determine length of string to place in table
      line_length = strlen( lf_sString ).
      WHILE line_length > 0.
    *   Scan for spaces
        lf_iPos = 72.
        if line_length < 72.
          lf_iPos = line_length.
        endif.
        lf_iTmp = lf_iPos - 1.
        lf_cChar = lf_sString+lf_iTmp(1).
        while lf_cChar <> ' ' and lf_iTmp > 1.
          lf_iTmp = lf_iTmp - 1.
          lf_cChar = lf_sString+lf_iTmp(1).
        endwhile.
        if lf_iTmp < 2.
          APPEND lf_sString TO output_table.
          SHIFT lf_sString LEFT BY 72 PLACES.
        else.
          lf_iTmp = lf_iTmp + 1.
          lf_sTmp = lf_sString(lf_iTmp).
          APPEND lf_sTmp TO output_table.
          SHIFT lf_sString LEFT BY lf_iTmp PLACES.
        endif.
        line_length = strlen( lf_sString ).
      ENDWHILE.
    endmethod.
    You can hack the code apart and basically it splits a string at a certain point.
    Excellent programming from SAP, just don't know who though

Maybe you are looking for

  • What's taking up my disk space?

    I have an iMac with a 500-gig drive. All my photos and videos are on an external drive. According to "info" the internal drive has 384Mb of disk space left! For the life of me I can't find what is taking up all the disk space and it's driving me craz

  • How do I correct error on e mail? Authenticatiom failed

    I cannot receive or send e-mail. Was working ok till got email from Verizon with new settings. I did that and now I get: Sending of password for user nettiew1 did not succeed. mail serve pop.verizon.net responded;Authentication failed. I don't rememb

  • Two questions about possible limitations in the Trial version

    1) I'm unable to format Date and Time using the Inspector/Table/Format option - is this because I'm using the Trial Version? The thing I'm trying to do is lose the day of the week in the default, so instead of "Sunday, August 26, 2007" it would read

  • Save custom filter for every document?

    Hello, sorry for my english ;) In FW CS3 it was possible to save a custom filter and so this filter was always shown in den filter list even when you open an new document. Now in FW CS4 you can only save a filter oder a style which is addicted to the

  • HT6114 How do I revert to OS X Mavericks v10.9.1 ?

    Hi all, after installing OS X Mavericks v10.9.2 all my videos display started to look weird, jumping frames/audio/scrubbing. This occurs in several apps like quicktime 7pro, final cut pro 6, even in youtube playing videos it's getting strange results