project QadFinancials > class BERSProcessor > method StopExternalInstances

Description

Stop all external instances


Parameters


oiReturnStatusoutputintegerReturn status of the method.


Internal usage


QadFinancials
method BERSProcessor.ERSProcessFinish


program code (program6/bersprocessor.p)

assign oiReturnStatus = -98.


/* BCInvoiceAPMatching */
if viBCInvoiceAPMatchingID <> 0 and
   viBCInvoiceAPMatchingID <> ? 
then do:
     <I-1 {bFcStopInstance
          &CLASS           = "BCInvoiceAPMatching"}>
     assign viBCInvoiceAPMatchingID = ?.
end.


/* BMfgPriceList */
if valid-handle(vhBMfgPriceListInst)
then do:
    <I-4 {bFcCloseAndStopInstance
         &CLASS           = "BMfgPriceList"}>
end.
else if viBMfgPriceListID <> 0 and
        viBMfgPriceListID <> ?
then do:
    <I-5 {bFcStopInstance
         &CLASS           = "BMfgPriceList"}>
end.
assign viBMfgPriceListID = ?.

/* BMfgUomConversion */
if valid-handle(vhBMfgUoMConvInst)
then do:
    <I-8 {bFcCloseAndStopInstance
         &CLASS           = "BMfgUoMConv"}>
end.
else if viBMfgUoMConvID <> 0 and
        viBMfgUoMConvID <> ?
then do:
    <I-9 {bFcStopInstance
         &CLASS           = "BMfgUoMConv"}>
end.
assign viBMfgUoMConvID = ?.

if oiReturnStatus = -98 then assign oiReturnStatus = 0.