Does the CssClass property in Web Server Controls work with AJAX ?

  •  12-15-2006, 5:39 PM

    Does the CssClass property in Web Server Controls work with AJAX ?

    I built an ASP.NET 2.0 web site in my computer which has about 30 web pages.

     

    I needed to use AJAX ( latest version ) only in the last page.

     

    So I created a web site with just one page to test the “ASP.NET Ajax-Enabled Web Site” code of this page separately before integrating it with the previous big web site which is based simply on ASP.NET.

     

    Both web sites work fine separately but when I added the web page with the AJAX code and also the modified web.config, it messed up the CSS formats( coded in the AB.css file )  on all Web controls  that use the CssClass property. As result of that the text appears only with its default attributes with big black character founts which destroy the aesthetics and organization of the pages.

     

    Here is a simple code example where the this problem appears:

     

    <asp:Label ID="usernameLb"  CssClass="Test" runat="server" ></asp:Label>

     

    And here is its CSS code ( inside a “.css” file ) :

     

    .Test

    {

      position:absolute;

      left:450px;

      top:110px;

      z-index:3;

      color: #0000ff;

      font-family: Verdana,Arial,Helvetica;

      font-size: 15px;

      font-weight: normal;

    }

     

     

    What could be the cause ?

     

    ( my OS is windows XP prof and I am using Visual Studio 2005 and IE 6 )
View Complete Thread