+ Start a Discussion

Trigger To Block Creation Without Error

I have read the cookbook and see that I can use a trigger to block the creation of a record by throwing an error.


Is there a way to do it without throwing the error?


I need on creation of a task to check certain values and if they sync up I have to create a different object and not save (or delete after insert which doesn't seem possible) the original task.






You can try using @future method where in you can pass the TaskId


and in the future method you can delete the original Task.


Hrm. Seems easy enough to test.


Thanks, will let you know if it works.