Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

ASP.NET page layout using css

  • 06-10-2009 11:20am
    #1
    Registered Users, Registered Users 2 Posts: 1,210 ✭✭✭


    Hi guys,

    I'm trying to layout an ASP page using CSS. I'm stuck at the very basics unfortunately :o I have a dropdown which I want to align to the right of the page but nothing is happening, this is what i have:
    body {
    }
    .right
    {
    position:absolute;
    right:0px;
    width:300px;
    background-color:#b0e0e6;
    }
    <%@ Page Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="Products.aspx.cs" Inherits="Default2" Title="Untitled Page" %>
    <asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <asp: DropDownList ID="DropDownList1" runat="server" CssClass="right">
    </asp: DropDownList>
    </asp:Content>

    any help appreciated.


Comments

  • Registered Users, Registered Users 2 Posts: 1,210 ✭✭✭20goto10


    I knew it was a sily question. I was missing a link to the StyleSheet file in my page:

    <link rel="stylesheet" type="text/css" href="StyleSheet.css" />


  • Registered Users, Registered Users 2 Posts: 1,210 ✭✭✭20goto10


    Ok i have my layout, but now I can't figure out how to stop the controls bunching up on each other when resizing the browser. Any ideas?


  • Registered Users, Registered Users 2 Posts: 7,468 ✭✭✭Evil Phil


    This is a web design rather than a programming issue, and for the record asp and asp.net are different technologies.


  • Registered Users, Registered Users 2 Posts: 1,210 ✭✭✭20goto10


    OK thanks. Where do I go to ask this question? I am talking about ASP.NET, visual studio 2005 to be precise.


  • Registered Users, Registered Users 2 Posts: 128 ✭✭johnny_rambo


    .right
    {
    position:relative;
    float: right;
    width:300px;
    background-color:#b0e0e6;
    }


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 1,210 ✭✭✭20goto10


    controls still bunch up...


  • Registered Users, Registered Users 2 Posts: 128 ✭✭johnny_rambo


    20goto10 wrote: »
    controls still bunch up...

    Can you post the code for the controls on the aspx page?


Advertisement