11/26/2024 3:25:15 AM
|
|
slxdeveloper.com Community Forums |
|
|
|
The Forums on slxdeveloper.com are now retired. The forum archive will remain available for the time being. Thank you for your participation on slxdeveloper.com!
Forum to discuss writing script in Architect plugins for SalesLogix & general SalesLogix customization topics (for Windows client only). View the code of conduct for posting guidelines.
|
|
|
|
OnDeletedRow versus OnDeleteRow
Posted: 26 Jun 06 1:53 PM
|
fiogf49gjkf0d I understand the difference between these two events, however I have a question as to which makes the most sense to use in my situation.
I have a datagrid that uses the standard Add/Edit/Delete right-click options and built-in functionality. However, when a user chooses to delete a record off of this datagrid I need to do a cascade delete down to the related (1 to 1) custom table. If I use OnDeleteRow and a user answers 'No' to the right-click>Delete question "Are you sure you want to delete this item?", will this event still fire? I guess I just want to make sure what the best practice would be to use. Is it best to just use the OnDeletedRow and delete from custom table where recordid not in maintable?
Please advise...Thanks! |
|
|
|
Re: OnDeletedRow versus OnDeleteRow
Posted: 26 Jun 06 3:47 PM
|
fiogf49gjkf0d OnDeletedRow is called AFTER the row is deleted. OnDeleteRow is called before. I use OnDeleteRow to capture the primary key into the form's private properties (so that it passes the event boundary). I then use OnDeletedRow to call my CascadeDelete(Table, PrimaryKey) routine. OnDeletedRow will NOT fire if the record is not deleted so your cascade method won't fire and shouldn't in this instance. |
|
|
|
You can
subscribe to receive a daily forum digest in your
user profile. View the site code
of conduct for posting guidelines.
Forum RSS Feed - Subscribe to the forum RSS feed to keep on top of the latest forum activity!
|
|
|
|
|
|
|
|