I am new to coldfusion and html althouth I am learning fast and getting by.
Can anybody tell me how to run a section of cold fusion code on the ONCLICK event of a button and then go to an href location. Do I have to run code in another template or can I embed the code in a function or procedure within the same template??
For Example, I have a grid with data from a table with contains bacthes of transactions. My grid displays Batchid, Open date, close date, status, etc...
Under my grid, I have 3 buttons View batch, Delete batch, Close batch.
When My viewbatch button is clicked, I want to go to another page which will display the batch contents using the batchid of the selected batch(that was simple). But my problem is for the other two buttons. For the delete, I want to send a delete sql statement to the table for the selected batch and refresh(point back to) same page. For close, I want to send an update query to the table for the selected batch and return to the same page.
I am an experieced vb programmer and I think this is what's causing all of my problems.
Should I think of redesigning the process (layout of GUI) or is this an okay way of doing it??
Is this a javascipt thing or can it be done using coldfusion tags alone??
I would really appreciate any feedback.