GoingforGold
|
| Posted: 05/26/2003, 7:35 AM |
|
I would like to use the updateable grid to select records by checkbox (and select all records on page)then add these records to a new table.
Is this possible. (feasible)
I am Using Access ASP
|
|
|
 |
rrodgers
|
| Posted: 05/26/2003, 10:48 AM |
|
I think the example pack that came with ccs2 has examples similar to this. The ones listed under "Working with Multiple Selections" look like a good place to start.
rob
|
|
|
 |
glerma
|
| Posted: 05/26/2003, 9:20 PM |
|
RE: select all records on page
Here are two handy Javascript functions that you can use for selecting and de-selecting all checkboxes on a form.
STEPS:
1. Add the following code to your html head.
2. //CHANGE document.formname TO YOUR OWN FORMNAME!!!
3a. To check boxes, create a hyper link and point the href address to javacript:checkAll();
3b. To uncheck all boxes, create another hyperlink and point the href address to javascript:uncheckAll();
THAT's ALL!
<!-- Begin Code
<script>
function checkAll() {
//CHANGE document.formname TO YOUR OWN FORMNAME!!!
with (document.formname) {
for (var i=0; i < elements.length; i++) {
if (elements.type == 'checkbox' ) {
elements.checked = true;
}
}
}
}
function uncheckAll() {
//CHANGE document.formname TO YOUR OWN FORMNAME!!!
with (document.gridSiteFiles) {
for (var i=0; i < elements.length; i++) {
if (elements.type == 'checkbox' ) {
elements.checked = false;
}
}
}
}
</script>
// End Code-->
|
|
|
 |
|