[CLOSED] How to Apply Styles To TopBar

  1. #1

    [CLOSED] How to Apply Styles To TopBar

    Hi all,,

    While Im Trying To Apply css to TOpBar it is Not Working. just see the Below Code

    .pnlcss
             {
                 background-color:#F0F1DA;
             }
    
     <ext:Panel ID="pnlCenter" runat="server" Border="false" Layout="card" ActiveIndex="0" BodyCssClass="pnlcss" AutoScroll="true">
                            <TopBar>
                                <ext:Toolbar Flat="false" ID="toolbar"  runat="server" Cls="pnlcss"  >
                                    <Items>
                                        <ext:ToolbarFill runat="server" ID="toolFill" />
                                        <ext:Button ID="btnRefresh" Text="Refresh" runat="server" Icon="Reload">
                                            <DirectEvents>
                                                <Click OnEvent="btnRefresh_Click">
                                                </Click>
                                            </DirectEvents>
                                        </ext:Button>
                                    </Items>
                                </ext:Toolbar>
                            </TopBar>
                                  
                            </Items>
                        </ext:Panel>
    But for the Top bar The stye will not change..

    so plz Guide Me Hoe to Apply style(Css) for TopBar.

    Thanks In Advance
    Last edited by Daniil; Nov 12, 2010 at 5:55 AM. Reason: [CLOSED]
  2. #2
    Hi,

    There is an image as background. It needs to disable it.

    Example Css class
    .myClass {
        background-color: Red;
        background-image: none;
    }
    Example
    <%@ Page Language="C#" %>
    
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
    
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head runat="server">
        <title>Ext.Net Example</title>
    
        <style type="text/css">
            .myClass {
                background-color: Red;
                background-image: none;
            }
        </style>
    </head>
    <body>
        <form runat="server">
        <ext:ResourceManager runat="server" />
        <ext:Toolbar runat="server" Cls="myClass">
            <Items>
                <ext:DisplayField runat="server" Text="Hello!" />
            </Items>
        </ext:Toolbar>
        </form>
    </body>
    </html>
  3. #3
    Thanks Daniil it will work fine..

Similar Threads

  1. [CLOSED] Override styles
    By FVNoel in forum 1.x Legacy Premium Help
    Replies: 1
    Last Post: Mar 15, 2012, 3:19 PM
  2. [CLOSED] More questions about Styles
    By supera in forum 2.x Legacy Premium Help
    Replies: 4
    Last Post: Jan 26, 2012, 12:40 PM
  3. [CLOSED] Styles don't apply to labels in toolbar
    By rthiney in forum 1.x Legacy Premium Help
    Replies: 2
    Last Post: Jul 30, 2010, 2:35 PM
  4. [CLOSED] [1.0] EditableGrid Apply to selection apply to all
    By ashton.lamont in forum 1.x Legacy Premium Help
    Replies: 4
    Last Post: Feb 24, 2010, 5:49 PM
  5. [CLOSED] [1.0] MVC PartialViews and styles?
    By Timothy in forum 1.x Legacy Premium Help
    Replies: 14
    Last Post: Feb 14, 2010, 4:12 PM

Posting Permissions