Quantcast
Channel: PHPExcel Forum Rss Feed
Viewing all articles
Browse latest Browse all 2707

New Post: How to put borders around my output in PHPexcel in a Dynamic way

$
0
0
Can anyone help me how to put borders around in my output arrays in my report in excel using PHPexcel.

I read the documentation but the example is in Static and you need to set the number already.

I want to do is when all arrays is transferred to excel all of them will have borders.
$result = array();

       for ( $n = 1; $n <=35; $n++ ){

        $name = isset($_POST['name'.$n]) ? $_POST['name'.$n] : "";
              if(!$name)
              {
                 continue;
              } 

        $no = 0+$n;
        $aic = isset($_POST['aic'.$n]) ? $_POST['aic'.$n] : "";
        $repcode = isset($_POST['repcode']) ? $_POST['repcode'] : "";
        $optA = isset($_POST['optA'.$n]) ? $_POST['optA'.$n] : "";
        $optB = isset($_POST['optB'.$n]) ? $_POST['optB'.$n] : "";
        $optC = isset($_POST['optC'.$n]) ? $_POST['optC'.$n] : "";
        $optD = isset($_POST['optD'.$n]) ? $_POST['optD'.$n] : "";
        $total = isset($_POST['total'.$n]) ? $_POST['total'.$n] : "";
        $remarks = '';

        $result[] = array(
              $no,
              "PRO13325-".$aic,
              $repcode,
              $name,
              $optA,
              $optB,
              $optC,
              $optD,
              $total,
              $remarks );
        }

Viewing all articles
Browse latest Browse all 2707

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>