CodeCharge Studio
search Register Login  

Web Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.

YesSoftware Forums -> CodeCharge Studio -> PHP

 Editable Grid with delete checkbox BeforeExecuteDelete

Print topic Send  topic

Author Message

Posts: 46
Posted: 04/07/2017, 2:31 PM Quote message

i have Editable Grid with delete checkbox.
so user can select multiple checkbox to delete items from table(grid).

i need logged before user delete items from table. BeforeExecuteDelete
basically i need items user selected only for delete. items to delete on editable grid insert on new table for logging.

dont know how to implement on BeforeExecuteDelete. appreciate your help
View profile  Send private message

Posts: 639
Posted: 04/25/2017, 12:22 AM Quote message

It''s $db connection heavy but you can use the on validate row to get the checkbox value and any field from the row and insert those values into a table.
Central Coast, NSW, Australia.

View profile  Send private message

Posts: 513
Posted: 08/31/2017, 1:10 AM Quote message

@oasisp - you can certainly do it with the BeforeExecuteDelete to collect the values from the form and executing some Custom SQL to put it in the table. This will execute once for each ticked row. The correct 'row' detail will be collected so you don't need to keep track.

(this isn't working code but should give a pointer)

function EditableGrid_ds_BeforeExecuteDelete

$EditableGrid_ds_BeforeExecuteDelete = true;
$Component = & $sender;
$Container = & CCGetParentContainer($sender);
global $EditableGrid; //Compatibility

// get the values from the Edittable Grid and add them to the Custom SQL
$db = new clsDBConnection1();
$SQL = "INSERT INTO backuplog (status, userid) ".
"VALUES (". $db->ToSQL($Container->status->GetFormattedValue() ,ccsInteger) .",". $db->ToSQL(CCGetUserID(),ccsInteger) .")";



CCS 3/4/5 ASP Classic, VB.NET, PHP
Melbourne, Victoria, Australia
View profile  Send private message

Add new topic Reply to topic Subscribe to topic   

These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit

Web Database

Join thousands of Web developers who build Web applications with minimal coding.

Home   |    Search   |    Members   |    Register   |    Login

Powered by UltraApps Forum created with CodeCharge Studio
Copyright 2003-2004 by  and YesSoftware, Inc.