[CLOSED] Checkbox is not rendering for Empty text in MultiCombo

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1

    [CLOSED] Checkbox is not rendering for Empty text in MultiCombo

    Hi,
    In Ext.Net 2.5 version, the checkbox is NOT rendering for the listitem which has Text="" and Value = something in the MultiCombo. Please see the below example code and picked from Ext.Net 2.5 Examples. Please let us know the solution ASAP.
    Please see the attached screenshot

    <%@ Page Language="C#" %>
    
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
    
    <!DOCTYPE html>
    
    <html>
    <head runat="server">
        <title>MultiCombo - Ext.NET Examples</title>
        <link href="/resources/css/examples.css" rel="stylesheet" />
        <style type="text/css">
             .x-boundlist-item
            {
                font-size: 11px;
                height: 24px;
            }
        </style>
        <script>
            var updateButtonText = function (item, checked) {
                var text = [];
                
                item.parentMenu.items.each(function (item) {
                    if (item.checked) {
                       text.push(item.text);
                    }
                });
                
                if (text.length == 0) {
                    App.Button1.setText("[Select Colors]");
                } else {
                    App.Button1.setText("[" + text.join(",") + "]");
                }
            };
        </script>
    </head>
    <body>
        <form runat="server">
            <ext:ResourceManager runat="server" />
            
            <h2>Simple MultiCombo</h2>
            
            <ext:MultiCombo runat="server" Width="260">
                <Items>
                    <ext:ListItem Text="Item 1" Value="1" />
                    <ext:ListItem Text="Item 2" Value="2" />
                    <ext:ListItem Text="Item 3" Value="3" />
                    <ext:ListItem Text="Item 4" Value="4" />
                    <ext:ListItem Text="Item 5" Value="5" />
                    <ext:ListItem Text=" " Value="10" />
                </Items>
                
                <SelectedItems>
                    <ext:ListItem Value="2" />
                    <ext:ListItem Index="4" />
                </SelectedItems>
            </ext:MultiCombo>
            <br />
            
            <h2>MultiCombo with WrapBySquareBrackets</h2>
            
            <ext:MultiCombo 
                runat="server" 
                WrapBySquareBrackets="true" 
                Width="260">
                <Items>
                    <ext:ListItem Text="Item 1" Value="1" />
                    <ext:ListItem Text="Item 2" Value="2" />
                    <ext:ListItem Text="Item 3" Value="3" />
                    <ext:ListItem Text="Item 4" Value="4" />
                    <ext:ListItem Text="Item 5" Value="5" />
    <ext:ListItem Text=" " Value="10" />
                </Items>
                
                <SelectedItems>
                    <ext:ListItem Value="2" />
                    <ext:ListItem Index="4" />
                </SelectedItems>
            </ext:MultiCombo>
            <br />
            
            <h2>MultiCombo with SelectionMode="Selection"</h2>
            
            <p>Selected items are highlighted.</p>
            
            <ext:MultiCombo runat="server" SelectionMode="Selection" Width="260">
                <Items>
                    <ext:ListItem Text="Item 1" Value="1" />
                    <ext:ListItem Text="Item 2" Value="2" />
                    <ext:ListItem Text="Item 3" Value="3" />
                    <ext:ListItem Text=" " Value="10" />
                    <ext:ListItem Text="Item 4" Value="4" />
                    <ext:ListItem Text="Item 5" Value="5" />
                </Items>
                
                <SelectedItems>
                    <ext:ListItem Value="2" />
                    <ext:ListItem Index="4" />
                </SelectedItems>
            </ext:MultiCombo>
            <br />
            
            <h2>MultiCombo with SelectionMode="All" (checkboxes and highlight)</h2>
            
            <p>Selected items are highlighted and checked.</p>
            
            <ext:MultiCombo runat="server" SelectionMode="All" Width="260">
                <Items>
                    <ext:ListItem Text="Item 1" Value="1" />
                    <ext:ListItem Text="Item 2" Value="2" />
                    <ext:ListItem Text="Item 3" Value="3" />
                    <ext:ListItem Text=" " Value="10" />
                    <ext:ListItem Text="Item 4" Value="4" />
                    <ext:ListItem Text="Item 5" Value="5" />
                </Items>
                
                <SelectedItems>
                    <ext:ListItem Value="2" />
                    <ext:ListItem Index="4" />
                </SelectedItems>
            </ext:MultiCombo>
            <br />
            
            <h2>Button with Menu to emulate MultiCombo</h2>
            
            <ext:Button 
                ID="Button1" 
                runat="server" 
                Icon="Rgb" 
                Text="[Select Colors]" 
                Width="200">
                <Menu>
                    <ext:Menu runat="server" Width="200">
                        <Defaults>
                            <ext:Parameter Name="HideOnClick" Value="false" Mode="Raw" />
                        </Defaults>
                        <Items>
                            <ext:CheckMenuItem runat="server" Text="Red" CheckHandler="updateButtonText" Width="194" />
                            <ext:CheckMenuItem runat="server" Text="Green" CheckHandler="updateButtonText" />
                            <ext:CheckMenuItem runat="server" Text="Blue" CheckHandler="updateButtonText" />
                        </Items>                    
                    </ext:Menu>
                </Menu>
            </ext:Button>
        </form>
    </body>
    </html>
    Attached Thumbnails Click image for larger version. 

Name:	MultiComboIssue.PNG 
Views:	151 
Size:	19.9 KB 
ID:	25107  
    Last edited by fabricio.murta; Apr 13, 2018 at 5:39 PM. Reason: no feedback from the user in 7+ days

Similar Threads

  1. Replies: 1
    Last Post: Jan 30, 2014, 5:38 AM
  2. [CLOSED] MultiCombo checkbox problem
    By PoloTheMonk in forum 2.x Legacy Premium Help
    Replies: 3
    Last Post: Jun 04, 2013, 7:19 AM
  3. [CLOSED] MultiCombo collapses on a CheckBox click in IE8.
    By Leonid_Veriga in forum 2.x Legacy Premium Help
    Replies: 5
    Last Post: Feb 18, 2013, 8:30 AM
  4. [CLOSED] Multicombo always show the same text
    By jmcantrell in forum 1.x Legacy Premium Help
    Replies: 1
    Last Post: May 28, 2012, 9:23 AM
  5. [CLOSED] [1.0] Multicombo not Rendering After SVN Update
    By amitpareek in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Nov 17, 2009, 6:18 AM

Tags for this Thread

Posting Permissions