$bal = get_open_balance($myrow['supplier_id'], $from, $convert);
$init[0] = $init[1] = 0.0;
$init[0] = round2(abs($bal['charges']), $dec);
$init[1] = round2(Abs($bal['credits']), $dec);
$init[2] = round2($bal['Allocated'], $dec);
$bal = get_open_balance($myrow['supplier_id'], $from, $convert);
$init[0] = $init[1] = 0.0;
$init[0] = round2(abs($bal['charges']), $dec);
$init[1] = round2(Abs($bal['credits']), $dec);
$init[2] = round2($bal['Allocated'], $dec);