Help making css styles work

Discussion in 'ASP .Net' started by keithb, Mar 14, 2006.

  1. keithb

    keithb Guest

    My ASP.NET 2.0 application has a User Control that contains a DataList that
    is unable to get style information from a style located in a css file in the
    themes folder. The user control CssClass and the DataList ItemStyle CssClass
    properties are both set to a valid name of a style in a stylesheet located
    in a subfolder of the App_Themes folder. The Web.config file contains a
    <pages theme property that references the name of the themes folder. Please
    take a look at the source code below and let me know if you see anything
    obviously wrong.

    Thanks,

    Keith


    <!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><title>
    Welcome to Build Task Manager
    </title><link href="App_Themes/BTMDefault/BTMDefault.css" type="text/css"
    rel="stylesheet" /></head>
    <body>
    <form name="aspnetForm" method="post" action="default.aspx"
    id="aspnetForm">
    <div>
    <input type="hidden" name="__VIEWSTATE" id="__VIEWSTATE"
    value="/wEPDwULLTEwMDUyNjYzMjgPZBYCZg9kFgICAw9kFgICAw9kFgJmDzwrAAkBAA8WBB4IRGF0YUtleXMWAB4LXyFJdGVtQ291bnQCBGQWCAIBD2QWAgIBDw8WAh4EVGV4dAUJUmVtaW5kZXIxZGQCAg9kFgICAQ8PFgIfAgUJUmVtaW5kZXIyZGQCAw9kFgICAQ8PFgIfAgUJUmVtaW5kZXIzZGQCBA9kFgICAQ8PFgIfAgUJUmVtaW5kZXI0ZGRkPm7a8PKDeoSgdqYmo9uV4krJkaA="
    />
    </div>

    <table cellspacing="0" cellpadding="0" width="770" border="1">
    <tr>
    <td width="100" valign="top">
    List of Departments
    <br />
    List of Categories
    <br />
    </td>
    <td valign="top">
    &nbsp;
    <p align="left">
    <a href="Default.aspx">
    <img src="Images/BTMLogo.gif" border="0" />
    </a>
    </p>

    <table id="ctl00_Reminders1_list"
    class="ReminderListContent" cellspacing="0" border="0"
    style="width:670px;border-collapse:collapse;">
    <tr>
    <td class="ReminderListHead">
    Reminders
    </td>
    </tr><tr>
    <td class="ReminderListContent">
    <a id="ctl00_Reminders1_list_ctl01_HyperLink1">Reminder1</a>
    </td>
    </tr><tr>
    <td class="ReminderListContent">
    <a id="ctl00_Reminders1_list_ctl02_HyperLink1">Reminder2</a>
    </td>
    </tr><tr>
    <td class="ReminderListContent">
    <a id="ctl00_Reminders1_list_ctl03_HyperLink1">Reminder3</a>
    </td>
    </tr><tr>
    <td class="ReminderListContent">
    <a id="ctl00_Reminders1_list_ctl04_HyperLink1">Reminder4</a>
    </td>
    </tr>
    </table>



    </td>
    </tr>
    </table>
    </form>
    </body>
    </html>
     
    keithb, Mar 14, 2006
    #1
    1. Advertising

  2. keithb

    keithb Guest

    I found the problem... I had forgotten to precede the style name with a
    period. in the style sheet.

    Thanks,

    Keith

    "keithb" <> wrote in message
    news:...
    > My ASP.NET 2.0 application has a User Control that contains a DataList
    > that is unable to get style information from a style located in a css file
    > in the themes folder. The user control CssClass and the DataList ItemStyle
    > CssClass properties are both set to a valid name of a style in a
    > stylesheet located in a subfolder of the App_Themes folder. The Web.config
    > file contains a <pages theme property that references the name of the
    > themes folder. Please take a look at the source code below and let me know
    > if you see anything obviously wrong.
    >
    > Thanks,
    >
    > Keith
    >
    >
    > <!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><title>
    > Welcome to Build Task Manager
    > </title><link href="App_Themes/BTMDefault/BTMDefault.css" type="text/css"
    > rel="stylesheet" /></head>
    > <body>
    > <form name="aspnetForm" method="post" action="default.aspx"
    > id="aspnetForm">
    > <div>
    > <input type="hidden" name="__VIEWSTATE" id="__VIEWSTATE"
    > value="/wEPDwULLTEwMDUyNjYzMjgPZBYCZg9kFgICAw9kFgICAw9kFgJmDzwrAAkBAA8WBB4IRGF0YUtleXMWAB4LXyFJdGVtQ291bnQCBGQWCAIBD2QWAgIBDw8WAh4EVGV4dAUJUmVtaW5kZXIxZGQCAg9kFgICAQ8PFgIfAgUJUmVtaW5kZXIyZGQCAw9kFgICAQ8PFgIfAgUJUmVtaW5kZXIzZGQCBA9kFgICAQ8PFgIfAgUJUmVtaW5kZXI0ZGRkPm7a8PKDeoSgdqYmo9uV4krJkaA="
    > />
    > </div>
    >
    > <table cellspacing="0" cellpadding="0" width="770" border="1">
    > <tr>
    > <td width="100" valign="top">
    > List of Departments
    > <br />
    > List of Categories
    > <br />
    > </td>
    > <td valign="top">
    > &nbsp;
    > <p align="left">
    > <a href="Default.aspx">
    > <img src="Images/BTMLogo.gif" border="0" />
    > </a>
    > </p>
    >
    > <table id="ctl00_Reminders1_list"
    > class="ReminderListContent" cellspacing="0" border="0"
    > style="width:670px;border-collapse:collapse;">
    > <tr>
    > <td class="ReminderListHead">
    > Reminders
    > </td>
    > </tr><tr>
    > <td class="ReminderListContent">
    > <a id="ctl00_Reminders1_list_ctl01_HyperLink1">Reminder1</a>
    > </td>
    > </tr><tr>
    > <td class="ReminderListContent">
    > <a id="ctl00_Reminders1_list_ctl02_HyperLink1">Reminder2</a>
    > </td>
    > </tr><tr>
    > <td class="ReminderListContent">
    > <a id="ctl00_Reminders1_list_ctl03_HyperLink1">Reminder3</a>
    > </td>
    > </tr><tr>
    > <td class="ReminderListContent">
    > <a id="ctl00_Reminders1_list_ctl04_HyperLink1">Reminder4</a>
    > </td>
    > </tr>
    > </table>
    >
    >
    >
    > </td>
    > </tr>
    > </table>
    > </form>
    > </body>
    > </html>
    >
    >
     
    keithb, Mar 15, 2006
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Jerry III
    Replies:
    0
    Views:
    453
    Jerry III
    Oct 15, 2003
  2. Jeff Marken
    Replies:
    1
    Views:
    633
    Jerry III
    Oct 16, 2003
  3. =?Utf-8?B?R3VlbnRoZXIgU2NoYWJ1cw==?=

    CSS - Styles

    =?Utf-8?B?R3VlbnRoZXIgU2NoYWJ1cw==?=, Aug 25, 2004, in forum: ASP .Net
    Replies:
    2
    Views:
    1,876
    Vidar Petursson
    Oct 23, 2004
  4. A Traveler

    Diff CSS styles for diff INPUT TYPE='s?

    A Traveler, Aug 31, 2004, in forum: ASP .Net
    Replies:
    6
    Views:
    4,980
    Steve Fulton
    Aug 31, 2004
  5. Marc
    Replies:
    3
    Views:
    537
    Toby Inkster
    Jan 18, 2005
Loading...

Share This Page