Link to home
Start Free TrialLog in
Avatar of jbotts
jbotts

asked on

datapagesize property is not working

The following code will not increase the number of records in the table staffTable:
The table ID is "staffTable" with an attribute of datapagesize="3". Trying to increase the size of the table to include all the records in a table. The functions staffTable.firstPage() works, but not setting the property datapagesize=999999.

 <p>
        <button onclick="staffTable.datapagesize=999999;
                           staffTable.firstPage()">Show All</button>
        <button onclick="staffTable.datapagesize=3">Show Pages</button>
</p>
Avatar of bluV11t
bluV11t
Flag of Norway image

Could you try alert dataPageSize first? BTW do you get a JavaScript error?

<button onclick="alert(staffTable.dataPageSize); staffTable.datapagesize=999999;
                           staffTable.firstPage()">Show All</button>
ASKER CERTIFIED SOLUTION
Avatar of bluV11t
bluV11t
Flag of Norway image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of jbotts
jbotts

ASKER

bluV11t:
Neither of the suggestions worked.
jbotts
How many records are there? Have you tried setting it to f.ex. 20? Maybe you cannot set it higher than max number of records...
You could also try

document.getElementById('staffTable').datapagesize=999;
Avatar of jbotts

ASKER

Actually I tried this again and it worked.
Thanks,
Jim Botts