USP_DATAFORMTEMPLATE_ADD_DISBURSEMENTPROCESS
The save procedure used by the add dataform template "Disbursement Process Add Form".
Parameters
| Parameter | Parameter Type | Mode | Description | 
|---|---|---|---|
| @ID | uniqueidentifier | INOUT | The output parameter indicating the ID of the record added. | 
| @CONTEXTID | uniqueidentifier | IN | Input parameter indicating the context ID for the record being added. | 
| @CHANGEAGENTID | uniqueidentifier | IN | Input parameter indicating the ID of the change agent invoking the procedure. | 
| @NAME | nvarchar(100) | IN | Name | 
| @DESCRIPTION | nvarchar(255) | IN | Description | 
Definition
 Copy 
                                    
CREATE procedure dbo.USP_DATAFORMTEMPLATE_ADD_DISBURSEMENTPROCESS
(
    @ID uniqueidentifier = null output
      ,@CONTEXTID uniqueidentifier
    ,@CHANGEAGENTID uniqueidentifier = null
    ,@NAME nvarchar(100) = ''
    ,@DESCRIPTION nvarchar(255) = ''
)
as
set nocount on;
begin try 
  exec dbo.USP_DISBURSEMENTPROCESS_CREATE @ID output, @CONTEXTID, @CHANGEAGENTID, @NAME, @DESCRIPTION;
  -- Now add all invoices and credit memos to it...
  exec dbo.USP_DISBURSEMENTPROCESS_SELECTALLFILTEREDSCHEDULES @ID, @CHANGEAGENTID;
end try
begin catch
    exec dbo.USP_RAISE_ERROR;
    return 1;
end catch
return 0;