OnProcess - BusinessProcess
Event to place processing code
Type: Event
Syntax
Procedure OnProcess
Description
Create this procedure. This is where you put your processing code. At this point, your status panel (if any) is visible and you are ready to process.
Call DoProcess to start the batch process.
It is important to understand the difference between the OnProcess and DoProcess messages. It is expected that you will start a BPO process by sending the message DoProcess to the object. This is how the process is started. However, you will very rarely ever augment or change the DoProcess procedures - that is the job of OnProcess.
OnProcess is the event that we expect you to customize to actually run the process. That is where you drop your custom code. You will never explicitly send the message OnProcess. That is what DoProcess is used for.
If you are calling OnProcess directly, very little will work properly. When you do this, you are not allowing the BPO to initialize itself before starting and to de-initialize itself upon completion. You will get no status panel, no error redirection (which is crucial), and no status logging.
See the main BusinessProcess class topic for more information and samples.