Dear Sir,
Below code is working fine without master page and GridView is scrolling fine both side.
When we copy same code in master page GridView don't set height and width and it is gone out of screen.
Please help me.
Thanks
Arvind
<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true"
CodeFile="AtestGridViewScrollWithMaster.aspx.cs" Inherits="AtestGridViewScrollWithMaster" %>
<%@ Register Assembly="Microsoft.ReportViewer.WebForms, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91"
Namespace="Microsoft.Reporting.WebForms" TagPrefix="rsweb" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
<link href="../Styles/GridViewStyle.css" rel="stylesheet" />
<script src="../js/jquery-1.7.2.min.js"></script>
<link type="text/css" href="../css/ui-lightness/jquery-ui-1.8.19.custom.css" rel="stylesheet" />
<script type="text/javascript" src="../js/jquery-ui-1.8.19.custom.min.js"></script>
<script src="../GridViewScrollBothSide/jquery-1.9.1.min.js"></script>
<script src="../GridViewScrollBothSide/JavaScript.js"></script>
<script src="../GridViewScrollBothSide/GridViewScrollBothSide.js"></script>
<script type="text/javascript">
$(document).ready(function () {
$('#GvPaymentStatus').gridviewScroll({
width: 1080,
freezesize: 4, // Freeze Number of Columns.
height: 400,
headerrowcount: 1, //Freeze Number of Rows with Header.
arrowsize: 30,
varrowtopimg: "../GridViewScrollBothSide/ImageScroll/arrowvt.png",
varrowbottomimg: "../GridViewScrollBothSide/ImageScroll/arrowvb.png",
harrowleftimg: "../GridViewScrollBothSide/ImageScroll/arrowhl.png",
harrowrightimg: "../GridViewScrollBothSide/ImageScroll/arrowhr.png"
});
});
</script>
<script type="text/javascript">
$(function () {
debugger;
$("#<%= TxtStartDate.ClientID %>").datepicker({
showOn: 'button',
buttonImageOnly: true,
buttonImage: '../images/calendar.png',
dateFormat: 'mm/dd/yy',
changeMonth: true,
changeYear: true,
readOnly: true,
yearRange: "-1:+0"
//buttonImage: 'images/calendar.png',
//yearRange: "-1:+0" // last one years
//yearRange: "-1:10" // last one years and next Ten Year
//yearRange: new Date().getFullYear().toString() + ':' + new Date().getFullYear().toString() // Only Current Year
//yearRange:'2021:' + new Date().getFullYear().toString()
});
});
</script>
<script type="text/javascript">
$(function () {
debugger;
$("#<%= TxtEndDate.ClientID %>").datepicker({
showOn: 'button',
buttonImageOnly: true,
buttonImage: '../images/calendar.png',
dateFormat: 'mm/dd/yy',
changeMonth: true,
changeYear: true,
readOnly: true,
yearRange: "-1:+0"
//buttonImage: 'images/calendar.png',
//yearRange: "-1:+0" // last one years
//yearRange: "-1:10" // last one years and next Ten Year
//yearRange: new Date().getFullYear().toString() + ':' + new Date().getFullYear().toString() // Only Current Year
//yearRange:'2021:' + new Date().getFullYear().toString()
});
});
</script>
body { max-width: 1080px; margin: auto; left: 0; }
</asp:Content>
<asp:GridView ID="GvPaymentStatus" Font-Size="10px" runat="server" AutoGenerateColumns="false"
CssClass="mydatagriddivisionlist" EmptyDataText="No Record Found" EmptyDataRowStyle-ForeColor="Red"
EmptyDataRowStyle-Font-Bold="true" EmptyDataRowStyle-BorderStyle="None" HorizontalAlign="Left"
AllowSorting="true" OnSorting="OnSorting" Style="width: 100%; border-collapse: collapse;"
OnRowDataBound="GvPaymentStatus_RowDataBound">
<RowStyle CssClass="rows"></RowStyle>
<Columns>
</Columns>
</asp:GridView>