8 Replies - 651 Views - Last Post: 19 June 2019 - 12:58 PM

#1 aspfun   User is offline

  • D.I.C Head

Reputation: 1
  • View blog
  • Posts: 118
  • Joined: 16-January 13

How to add scroll bar in content page?

Posted 19 June 2019 - 11:40 AM

There are about 20 content pages in application with the same master page.

Master page only has company logo and application title.

How to add scroll bar so that various screen resolution monitor will scroll content under master page but keep logo and title at the same position?
Is This A Good Question/Topic? 0
  • +

Replies To: How to add scroll bar in content page?

#2 modi123_1   User is offline

  • Suitor #2
  • member icon



Reputation: 15262
  • View blog
  • Posts: 61,167
  • Joined: 12-June 08

Re: How to add scroll bar in content page?

Posted 19 June 2019 - 11:56 AM

In the master page, surround the asp:content with asp:panel.

Ex:
 <asp:Panel ID="panel1" runat="server" ScrollBars="Auto">
                <asp:ContentPlaceHolder ID="ContentPlaceHolder1" runat="server">
                </asp:ContentPlaceHolder>
            </asp:Panel>

Was This Post Helpful? 1
  • +
  • -

#3 aspfun   User is offline

  • D.I.C Head

Reputation: 1
  • View blog
  • Posts: 118
  • Joined: 16-January 13

Re: How to add scroll bar in content page?

Posted 19 June 2019 - 12:05 PM

Thank you but it scrolls master page as well.
Was This Post Helpful? 0
  • +
  • -

#4 modi123_1   User is offline

  • Suitor #2
  • member icon



Reputation: 15262
  • View blog
  • Posts: 61,167
  • Joined: 12-June 08

Re: How to add scroll bar in content page?

Posted 19 June 2019 - 12:09 PM

I made a quick example up, and no it does not do that for me.

Post how you are using it. Minimally extraneous stuff.
Was This Post Helpful? 0
  • +
  • -

#5 aspfun   User is offline

  • D.I.C Head

Reputation: 1
  • View blog
  • Posts: 118
  • Joined: 16-January 13

Re: How to add scroll bar in content page?

Posted 19 June 2019 - 12:14 PM

Here is my master page.

<%@ Master Language="VB" CodeFile="MasterPageDBDefault.master.vb" Inherits="MasterPageDBDefault" %>

<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<!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 id="Head1" runat="server">
    <title>Untitled Page</title>
   
    <style type="text/css">
        .body1 {
            background: url("images/backgroundjob.png");
            background-size: 2000px 250px;
            background-repeat: no-repeat;
        }
       
        .title {
            z-index: 1;
            position: relative;
            left: 310px;
            top: 40px;
            width: 380px;
            height: 100px;
        }
      
        .mainwrapper {
            position: fixed;
            width: 1000px;
            min-height: 800px;
            margin: 0 auto;
            top: 0px;
            left: 0px;
        }
        .content {
            z-index: 1;
            position: relative;
            left: -100px;
            top: -10px;
            width: 1200px;
            height: 600px;
            overflow: auto; 
        }
    </style>
   
</head>
<body class="body1">
    <form id="form1" runat="server">
    <telerik:RadScriptManager ID="ScriptManager1" runat="server" EnableTheming="True">
    </telerik:RadScriptManager>
    <div class="mainwrapper">
        <div>
            <div class="logo" id="Logo">
                <asp:Image ID="Image2" runat="server" ImageUrl="~/Images/logo_job.png" Width="380"
                    Height="100" />
            </div>
            <div class="title" id="Title">
                <asp:Image ID="Image1" runat="server" ImageUrl="~/Images/PP_TITLE.png" Width="380"
                    Height="50" />
            </div>
            
        </div>
     
        <asp:Panel ID="panel1" runat="server" CssClass="content">
            <asp:ContentPlaceHolder ID="cphMain" runat="server">
            </asp:ContentPlaceHolder>
        </asp:Panel>
      
    </div>
   
    </form>
</body>
</html>


Was This Post Helpful? 0
  • +
  • -

#6 modi123_1   User is offline

  • Suitor #2
  • member icon



Reputation: 15262
  • View blog
  • Posts: 61,167
  • Joined: 12-June 08

Re: How to add scroll bar in content page?

Posted 19 June 2019 - 12:23 PM

I dumped that into my throw away project and the scroll bars were inside the content and not the whole page.
Was This Post Helpful? 0
  • +
  • -

#7 DarenR   User is offline

  • D.I.C Lover

Reputation: 634
  • View blog
  • Posts: 4,209
  • Joined: 12-January 10

Re: How to add scroll bar in content page?

Posted 19 June 2019 - 12:37 PM

clear your cache and test it again
Was This Post Helpful? 0
  • +
  • -

#8 aspfun   User is offline

  • D.I.C Head

Reputation: 1
  • View blog
  • Posts: 118
  • Joined: 16-January 13

Re: How to add scroll bar in content page?

Posted 19 June 2019 - 12:50 PM

I did but no luck.

clear your cache and test it again
Was This Post Helpful? 0
  • +
  • -

#9 modi123_1   User is offline

  • Suitor #2
  • member icon



Reputation: 15262
  • View blog
  • Posts: 61,167
  • Joined: 12-June 08

Re: How to add scroll bar in content page?

Posted 19 June 2019 - 12:58 PM

The panel needs a defined heigrht.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1