Delete records from a table

The popup window contains the table I want to update and the popup window name is User Email. The database table name I’m trying to change is emails.

Here is the script to open the popup window.

param1 = event.source.parent.UnitNumber
if event.source.parent.getComponent(‘UnitTable’).selectedRow == -1: #No row selected in Unit Table
system.gui.warningBox(“You must select a unit before modifying email table!”,“No Unit Selected”)
else:
system.nav.openWindow(‘Popups/User Email’, {‘UnitNumber’ : param1, ‘UserType’ : ‘User’})
system.nav.centerWindow(‘Popups/User Email’)

Here’s a screen shot of the Overview screen that launches the popup window. I click on Change to execute the above script.