'dataPageSize' Example : dataPageSize « Javascript Properties « JavaScript Reference

JavaScript Reference
1. Event Handlers Reference
2. Javascript Collections
3. Javascript Methods
4. Javascript Objects
5. Javascript Properties
Java
Java Tutorial
Java Source Code / Java Documentation
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
C# / C Sharp
C# / CSharp Tutorial
ASP.Net
JavaScript DHTML
JavaScript Tutorial
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
PHP
Python
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
JavaScript Reference » Javascript Properties » dataPageSize 
'dataPageSize' Example

<!-- 
Example revised from 

The Web Programmer's Desk Reference
by Lazaro Issi Cohen and Joseph Issi Cohen 

ISBN: 1593270119
Publisher: No Starch Press 2004
-->    
<html>
<head>
<script language="javascript">
function rowEnter(){
    myTable.rows[myData.recordset.AbsolutePosition].style.backgroundColor = 'yellow';
}
function add(){
    myData.recordset.AddNew();
}
function del(){
    if (myData.recordset.RecordCount > 0
        myData.recordset.Delete();
}
</script>
<script for="myTable" event="onreadystatechange">
    if (this.readyState == 'complete'){ 
        this.rows(myData.recordset.AbsolutePosition).style.backgroundColor = 'yellow';
        myData.onrowenter = rowEnter;
    }
</script>
<script for="myData" event="onrowexit">
    for (var i = 1; i <= myData.recordset.RecordCount; i++){
        myTable.rows[i].style.backgroundColor = '';
    }
</script>
<script for="tableList" event="onclick">
    myData.recordset.AbsolutePosition = this.recordNumber;
    window.event.cancelBubble = true;
</script>
<script for="myData" event="oncellchange">
alert(event.dataFld);
</script>
</head>
<body>
<button onclick="add();">Add Record</button>
<button onclick="del();">Delete</button>
<button onclick="alert(firstname.dataFld);">dataFld</button>
<button onclick="alert(myDiv.dataFormatAs);">dataFormatAs</button>
<button onclick="alert(myTable.dataPageSize);">dataPage</button>
<button onclick="alert(myTable.dataSrc);">dataSrc</button>
<div datasrc="#myData" id="myDiv" dataformatas="text"></div>
<object classid="clsid:333C7BC4-460F-11D0-BC04-0080C7055A83" id="myData">
    <param name="DataURL" value="myfile.csv">
    <param name="UseHeader" value="True">
    <param name="TextQualifier" value="'">
</object>
<br>
<br>
First Name:&nbsp;<input id="firstname" type="text" datasrc="#myData" datafld="firstname"><br>
Last Name:&nbsp;<input id="lastname" type="text" datasrc="#myData" datafld="lastname"><br>
Income:&nbsp;<input id="income" type="text" datasrc="#myData" datafld="income"><br>
    <thead>
        <tr style="font-weight:bold">
            <td>First Name</td>
            <td>Last Name</td>
        </tr>
    </thead>
    <tbody>
    <tr id="tableList">
        <td><span datafld="firstname"></span></td>
        <td><span datafld="lastname"></span></td>
    </tr>
    </tbody>
</table>
</body>
</html>

<!--Contents of myfile.csv: -->
<!--
firstname:STRING,lastname:STRING
Joe,Smith
Manny,LastName
Tony,Belling
-->
    
      
      
Related examples in the same category
1. 'dataPageSize' Syntax and Note
2. 'dataPageSize' is applied to
www.java2java.com | Contact Us
Copyright 2010 - 2030 Java Source and Support. All rights reserved.
All other trademarks are property of their respective owners.