Linux ip-172-26-7-228 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 23 20:04:10 UTC 2023 x86_64
Your IP : 18.188.211.246
<?php
$main_src = substr($_SERVER['SCRIPT_FILENAME'], 0, strlen($_SERVER['SCRIPT_FILENAME']) - 7);
error_reporting(E_ALL);
ini_set('display_errors', TRUE);
ini_set('display_startup_errors', TRUE);
ini_set('max_execution_time', '300');
date_default_timezone_set('GMT+5:30');
// PHPExcel_Shared_Font::setAutoSizeMethod(PHPExcel_Shared_Font::AUTOSIZE_METHOD_EXACT);
if (PHP_SAPI == 'cli')
die('This example should only be run from a Web Browser');
/** Include PHPExcel */
$pdf_writer_class = '/var/www/html/univadmin/PHPExcel/Classes/PHPExcel.php';
require_once($pdf_writer_class);
function getheaders($objPHPExcel, $fileName)
{
//To Fit To Page while printing
$objPHPExcel->getActiveSheet()->getPageSetup()->setRowsToRepeatAtTopByStartAndEnd(1);
$objPHPExcel->getActiveSheet()->getPageSetup()->setFitToWidth(1);
$objPHPExcel->getActiveSheet()->getPageSetup()->setFitToHeight(0);
$objPHPExcel->getActiveSheet()->getPageSetup()->setHorizontalCentered(true);
$objPHPExcel->getActiveSheet()->getPageSetup()->setVerticalCentered(false);
// Redirect output to a client’s web browser (Excel5)
header('Content-Type: application/vnd.ms-excel');
header('Content-Disposition: attachment;filename="' . $fileName . '.xls"');
header('Cache-Control: max-age=0');
// If you're serving to IE 9, then the following may be needed
header('Cache-Control: max-age=1');
// If you're serving to IE over SSL, then the following may be needed
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past
header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified
header('Cache-Control: cache, must-revalidate'); // HTTP/1.1
header('Pragma: public'); // HTTP/1.0
ob_clean();
$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');
$objWriter->save('php://output');
}
function ResultStatsCategoryWise($aobj_context)
{
$year = $aobj_context->mobj_data["year"];
$examtype = $aobj_context->mobj_data["examtype"];
$sem = $aobj_context->mobj_data["sem"];
$examno = explode(',',$sem);
$_college = $aobj_context->mobj_data['college'];
$college = json_decode($_college,true);
$_degree = $aobj_context->mobj_data['degree'];
$degree = json_decode($_degree,true);
foreach($degree as $key => $val){
$deg .= "'".$val."',";
}
$degarr = substr_replace($deg ,"",-1);
foreach($college as $key => $val){
$coll .= "'".$val."',";
}
$collarr = substr_replace($coll ,"",-1);
foreach($examno as $key => $val){
$exam .= "'".$val."',";
}
$examarr = substr_replace($exam ,"",-1);
if($degarr == "'all'"){
$cnd1 = "";
}else{
$cnd1 = "and r.fdegree in ({$degarr})";
}
if($collarr == "'all'"){
$cnd2 = "";
}else{
$cnd2 = "and s.fcollcode in ({$collarr})";
}
$query = "select distinct r.fdegree as degree,d.fdescpn as descp, r.fexamno,
concat(d.fdeggrp,' - ',d.fexamname, ' - ' ,d. fresexamdate) as examname,c.fcollcode,
concat(c.fcollname, ' - ',c.ftown) as college,
sum(case when fgender='M' and s.fcaste = 'GM' then 1 else 0 end) as male_gm_appeared,
sum(case when fgender='F' and s.fcaste = 'GM' then 1 else 0 end) as female_gm_appeared,
sum(case when fclass <='fail' and fgender = 'M' and s.fcaste = 'GM' then 1 else 0 end) as male_gm_pass,
sum(case when fclass <='fail'and fgender='F' and s.fcaste = 'GM' then 1 else 0 end) as female_gm_pass,
sum(case when fclass >'fail'and fgender = 'M' and s.fcaste = 'GM' then 1 else 0 end) as male_gm_fail,
sum(case when fclass >'fail' and fgender='F' and s.fcaste = 'GM' then 1 else 0 end) as female_gm_fail,
sum(case when fgender='M' and s.fcaste = 'SC' then 1 else 0 end) as male_SC_appeared,
sum(case when fgender='F' and s.fcaste = 'SC' then 1 else 0 end) as female_SC_appeared,
sum(case when fclass <='fail' and fgender = 'M' and s.fcaste = 'SC' then 1 else 0 end) as male_SC_pass,
sum(case when fclass <='fail'and fgender='F' and s.fcaste = 'SC' then 1 else 0 end) as female_SC_pass,
sum(case when fclass >'fail'and fgender = 'M' and s.fcaste = 'SC' then 1 else 0 end) as male_SC_fail,
sum(case when fclass >'fail' and fgender='F' and s.fcaste = 'SC' then 1 else 0 end) as female_SC_fail,
sum(case when fgender='M' and s.fcaste = 'ST' then 1 else 0 end) as male_ST_appeared,
sum(case when fgender='F' and s.fcaste = 'ST' then 1 else 0 end) as female_ST_appeared,
sum(case when fclass <='fail' and fgender = 'M' and s.fcaste = 'ST' then 1 else 0 end) as male_ST_pass,
sum(case when fclass <='fail'and fgender='F' and s.fcaste = 'ST' then 1 else 0 end) as female_ST_pass,
sum(case when fclass >'fail'and fgender = 'M' and s.fcaste = 'ST' then 1 else 0 end) as male_ST_fail,
sum(case when fclass >'fail' and fgender='F' and s.fcaste = 'ST' then 1 else 0 end) as female_ST_fail,
sum(case when fgender='M' and s.fcaste = 'IIA' then 1 else 0 end) as male_IIA_appeared,
sum(case when fgender='F' and s.fcaste = 'IIA' then 1 else 0 end) as female_IIA_appeared,
sum(case when fclass <='fail' and fgender = 'M' and s.fcaste = 'IIA' then 1 else 0 end) as male_IIA_pass,
sum(case when fclass <='fail'and fgender='F' and s.fcaste = 'IIA' then 1 else 0 end) as female_IIA_pass,
sum(case when fclass >'fail'and fgender = 'M' and s.fcaste = 'IIA' then 1 else 0 end) as male_IIA_fail,
sum(case when fclass >'fail' and fgender='F' and s.fcaste = 'IIA' then 1 else 0 end) as female_IIA_fail,
sum(case when fgender='M' and s.fcaste = 'CAT-I' then 1 else 0 end) as male_CATI_appeared,
sum(case when fgender='F' and s.fcaste = 'CAT-I' then 1 else 0 end) as female_CATI_appeared,
sum(case when fclass <='fail' and fgender = 'M' and s.fcaste = 'CAT-I' then 1 else 0 end) as male_CATI_pass,
sum(case when fclass <='fail'and fgender='F' and s.fcaste = 'CAT-I' then 1 else 0 end) as female_CATI_pass,
sum(case when fclass >'fail'and fgender = 'M' and s.fcaste = 'CAT-I' then 1 else 0 end) as male_CATI_fail,
sum(case when fclass >'fail' and fgender='F' and s.fcaste = 'CAT-I' then 1 else 0 end) as female_CATI_fail,
sum(case when fgender='M' and s.fcaste = 'IIB' then 1 else 0 end) as male_IIB_appeared,
sum(case when fgender='F' and s.fcaste = 'IIB' then 1 else 0 end) as female_IIB_appeared,
sum(case when fclass <='fail' and fgender = 'M' and s.fcaste = 'IIB' then 1 else 0 end) as male_IIB_pass,
sum(case when fclass <='fail'and fgender='F' and s.fcaste = 'IIB' then 1 else 0 end) as female_IIB_pass,
sum(case when fclass >'fail'and fgender = 'M' and s.fcaste = 'IIB' then 1 else 0 end) as male_IIB_fail,
sum(case when fclass >'fail' and fgender='F' and s.fcaste = 'IIB' then 1 else 0 end) as female_IIB_fail,
sum(case when fgender='M' and s.fcaste = 'IIIA' then 1 else 0 end) as male_IIIA_appeared,
sum(case when fgender='F' and s.fcaste = 'IIIA' then 1 else 0 end) as female_IIIA_appeared,
sum(case when fclass <='fail' and fgender = 'M' and s.fcaste = 'IIIA' then 1 else 0 end) as male_IIIA_pass,
sum(case when fclass <='fail'and fgender='F' and s.fcaste = 'IIIA' then 1 else 0 end) as female_IIIA_pass,
sum(case when fclass >'fail'and fgender = 'M' and s.fcaste = 'IIIA' then 1 else 0 end) as male_IIIA_fail,
sum(case when fclass >'fail' and fgender='F' and s.fcaste = 'IIIA' then 1 else 0 end) as female_IIIA_fail,
sum(case when fgender='M' and s.fcaste = 'IIIB' then 1 else 0 end) as male_IIIB_appeared,
sum(case when fgender='F' and s.fcaste = 'IIIB' then 1 else 0 end) as female_IIIB_appeared,
sum(case when fclass <='fail' and fgender = 'M' and s.fcaste = 'IIIB' then 1 else 0 end) as male_IIIB_pass,
sum(case when fclass <='fail'and fgender='F' and s.fcaste = 'IIIB' then 1 else 0 end) as female_IIIB_pass,
sum(case when fclass >'fail'and fgender = 'M' and s.fcaste = 'IIIB' then 1 else 0 end) as male_IIIB_fail,
sum(case when fclass >'fail' and fgender='F' and s.fcaste = 'IIIB' then 1 else 0 end) as female_IIIB_fail
from (select distinct fregno,fdegree,fclass,fexamno from resmarks where fexamno in ($examarr)
and fyear = '{$year}'
and fexamtype = '{$examtype}') as r
inner join student s on r.fregno = s.fregno and r.fdegree = s.fdegree
inner join degree d on d.fdegree =r.fdegree and d.fexamno = r.fexamno
inner join college c on s.fcollcode = c.fcollcode where ifnull(fgender,'')<>''
$cnd1
$cnd2
group by s.fregno,s.fcollcode";
// var_dump($query);
// die();
$result = $aobj_context->pobj_db->GetAll($query);
// var_dump($result);
// die();
// var_dump($result);
$objPHPExcel = new PHPExcel();
$fileName = 'Category Report';
$objPHPExcel->getProperties()->setCreator("Uniclare")
->setLastModifiedBy("Me")->setTitle("My Excel Sheet")
->setSubject("My Excel Sheet")->setDescription("Excel Sheet")
->setKeywords("Excel Sheet")->setCategory("Me");
// Set active sheet index to the first sheet, so Excel opens this as the first sheet
$objPHPExcel->setActiveSheetIndex(0);
// Add column headers and make them bold
$styleArray = array(
'borders' => array(
'allborders' => array(
'style' => PHPExcel_Style_Border::BORDER_THIN,
'color' => array('argb' => '000000'),
),
),
);
$objPHPExcel->getActiveSheet()->getStyle('1:2')->getFont()->setBold(true);
$objPHPExcel->getActiveSheet()->getStyle('1:2')->getFont()->setSize(12);
$objPHPExcel->getActiveSheet()->freezePane('A1');
$objPHPExcel->getActiveSheet()->setCellValue('A1', 'Sl No')
->setCellValue('B1', 'Degree')
->setCellValue('C1', 'Description')
->setCellValue('D1', 'College Code')
->setCellValue('E1', 'College Name')
->setCellValue('F1', 'Exam No.')
->setCellValue('G1', 'GM Appeared')
->setCellValue('G2', 'Male')
->setCellValue('H2', 'Female')
->setCellValue('I2', 'Total')
->setCellValue('J1', 'GM Passed')
->setCellValue('J2', 'Male')
->setCellValue('K2', 'Female')
->setCellValue('L2', 'Total')
->setCellValue('M1', 'GM Fail')
->setCellValue('M2', 'Male')
->setCellValue('N2', 'Female')
->setCellValue('O2', 'Total')
->setCellValue('P1', 'CAT-I Appeared')
->setCellValue('P2', 'Male')
->setCellValue('Q2', 'Female')
->setCellValue('R2', 'Total')
->setCellValue('S1', 'CAT-I Passed')
->setCellValue('S2', 'Male')
->setCellValue('T2', 'Female')
->setCellValue('U2', 'Total')
->setCellValue('V1', 'CAT-I Fail')
->setCellValue('V2', 'Male')
->setCellValue('W2', 'Female')
->setCellValue('X2', 'Total')
->setCellValue('Y1', 'IIA Appeared')
->setCellValue('Y2', 'Male')
->setCellValue('Z2', 'Female')
->setCellValue('AA2', 'Total')
->setCellValue('AB1', 'IIA Passed')
->setCellValue('AB2', 'Male')
->setCellValue('AC2', 'Female')
->setCellValue('AD2', 'Total')
->setCellValue('AE1', 'IIA Fail')
->setCellValue('AE2', 'Male')
->setCellValue('AF2', 'Female')
->setCellValue('AG2', 'Total')
->setCellValue('AH1', 'IIB Appeared')
->setCellValue('AH2', 'Male')
->setCellValue('AI2', 'Female')
->setCellValue('AJ2', 'Total')
->setCellValue('AK1', 'IIB Passed')
->setCellValue('AK2', 'Male')
->setCellValue('AL2', 'Female')
->setCellValue('AM2', 'Total')
->setCellValue('AN1', 'IIB Fail')
->setCellValue('AN2', 'Male')
->setCellValue('AO2', 'Female')
->setCellValue('AP2', 'Total')
->setCellValue('AQ1', 'IIIA Appeared')
->setCellValue('AQ2', 'Male')
->setCellValue('AR2', 'Female')
->setCellValue('AS2', 'Total')
->setCellValue('AT1', 'IIIA Passed')
->setCellValue('AT2', 'Male')
->setCellValue('AU2', 'Female')
->setCellValue('AV2', 'Total')
->setCellValue('AW1', 'IIIA Fail')
->setCellValue('AW2', 'Male')
->setCellValue('AX2', 'Female')
->setCellValue('AY2', 'Total')
->setCellValue('AZ1', 'IIIB Appeared')
->setCellValue('AZ2', 'Male')
->setCellValue('BA2', 'Female')
->setCellValue('BB2', 'Total')
->setCellValue('BC1', 'IIIB Passed')
->setCellValue('BC2', 'Male')
->setCellValue('BD2', 'Female')
->setCellValue('BE2', 'Total')
->setCellValue('BF1', 'IIIB Fail')
->setCellValue('BF2', 'Male')
->setCellValue('BG2', 'Female')
->setCellValue('BH2', 'Total')
->setCellValue('BI1', 'SC Appeared')
->setCellValue('BI2', 'Male')
->setCellValue('BJ2', 'Female')
->setCellValue('BK2', 'Total')
->setCellValue('BL1', 'SC Passed')
->setCellValue('BL2', 'Male')
->setCellValue('BM2', 'Female')
->setCellValue('BN2', 'Total')
->setCellValue('BO1', 'SC Fail')
->setCellValue('BO2', 'Male')
->setCellValue('BP2', 'Female')
->setCellValue('BQ2', 'Total')
->setCellValue('BR1', 'ST Appeared')
->setCellValue('BR2', 'Male')
->setCellValue('BS2', 'Female')
->setCellValue('BT2', 'Total')
->setCellValue('BU1', 'ST Passed')
->setCellValue('BU2', 'Male')
->setCellValue('BV2', 'Female')
->setCellValue('BW2', 'Total')
->setCellValue('BX1', 'ST Fail')
->setCellValue('BX2', 'Male')
->setCellValue('BY2', 'Female')
->setCellValue('BZ2', 'Total');
$objPHPExcel->getActiveSheet()->getStyle('A1:BZ2')->applyFromArray($styleArray);
$objPHPExcel->getActiveSheet()->mergeCells('A1:A2');
$objPHPExcel->getActiveSheet()->mergeCells('B1:B2');
$objPHPExcel->getActiveSheet()->mergeCells('C1:C2');
$objPHPExcel->getActiveSheet()->mergeCells('D1:D2');
$objPHPExcel->getActiveSheet()->mergeCells('E1:E2');
$objPHPExcel->getActiveSheet()->mergeCells('F1:F2');
$objPHPExcel->getActiveSheet()->mergeCells('G1:I1');
$objPHPExcel->getActiveSheet()->mergeCells('J1:L1');
$objPHPExcel->getActiveSheet()->mergeCells('M1:O1');
$objPHPExcel->getActiveSheet()->mergeCells('P1:R1');
$objPHPExcel->getActiveSheet()->mergeCells('S1:U1');
$objPHPExcel->getActiveSheet()->mergeCells('V1:X1');
$objPHPExcel->getActiveSheet()->mergeCells('Y1:AA1');
$objPHPExcel->getActiveSheet()->mergeCells('AB1:AD1');
$objPHPExcel->getActiveSheet()->mergeCells('AE1:AG1');
$objPHPExcel->getActiveSheet()->mergeCells('AH1:AJ1');
$objPHPExcel->getActiveSheet()->mergeCells('AK1:AM1');
$objPHPExcel->getActiveSheet()->mergeCells('AN1:AP1');
$objPHPExcel->getActiveSheet()->mergeCells('AQ1:AS1');
$objPHPExcel->getActiveSheet()->mergeCells('AT1:AV1');
$objPHPExcel->getActiveSheet()->mergeCells('AW1:AY1');
$objPHPExcel->getActiveSheet()->mergeCells('AZ1:BB1');
$objPHPExcel->getActiveSheet()->mergeCells('BC1:BE1');
$objPHPExcel->getActiveSheet()->mergeCells('BF1:BH1');
$objPHPExcel->getActiveSheet()->mergeCells('BI1:BK1');
$objPHPExcel->getActiveSheet()->mergeCells('BL1:BN1');
$objPHPExcel->getActiveSheet()->mergeCells('BO1:BQ1');
$objPHPExcel->getActiveSheet()->mergeCells('BR1:BT1');
$objPHPExcel->getActiveSheet()->mergeCells('BU1:BW1');
$objPHPExcel->getActiveSheet()->mergeCells('BX1:BZ1');
$objPHPExcel->getActiveSheet()->getRowDimension('1')->setRowHeight(25);
$objPHPExcel->getActiveSheet()->getStyle('A1:BZ1')->getAlignment()->setWrapText(true);
$objPHPExcel->getActiveSheet()->getStyle('A1:BZ1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('A1:BZ1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);
foreach ($result as $key => $value) {
$slNo = $key + 3;
// var_dump($objPHPExcel->getActiveSheet()->setCellValue('A' . $slNo, $slNo)->getColumnDimension('A')->setwidth(6.5),'dddd');
// die();
$objPHPExcel->getActiveSheet()->getRowDimension($slNo)->setRowHeight(25);
$objPHPExcel->getActiveSheet()->setCellValue('A' . $slNo, $slNo - 2)->getColumnDimension('A')->setwidth(6);
$objPHPExcel->getActiveSheet()->setCellValue('B' . $slNo, $value['degree'])->getColumnDimension('B')->setwidth(9);
$objPHPExcel->getActiveSheet()->setCellValue('C' . $slNo, $value['descp'])->getColumnDimension('C')->setwidth(40);
$objPHPExcel->getActiveSheet()->setCellValue('D' . $slNo, $value['fcollcode'])->getColumnDimension('D')->setwidth(15);
$objPHPExcel->getActiveSheet()->setCellValue('E' . $slNo, $value['college'])->getColumnDimension('E')->setwidth(50);
$objPHPExcel->getActiveSheet()->setCellValue('F' . $slNo, $value['fexamno'])->getColumnDimension('F')->setwidth(15);
$objPHPExcel->getActiveSheet()->setCellValue('G' . $slNo, $value['male_gm_appeared'])->getColumnDimension('G')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('H' . $slNo, $value['female_gm_appeared'])->getColumnDimension('H')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('I' . $slNo, $value['male_gm_appeared'] + $value['female_gm_appeared'])->getColumnDimension('I')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('J' . $slNo, $value['male_gm_pass'])->getColumnDimension('J')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('K' . $slNo, $value['female_gm_pass'])->getColumnDimension('K')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('L' . $slNo, $value['male_gm_pass'] + $value['female_gm_pass'])->getColumnDimension('L')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('M' . $slNo, $value['male_gm_fail'])->getColumnDimension('M')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('N' . $slNo, $value['female_gm_fail'])->getColumnDimension('N')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('O' . $slNo, $value['male_gm_fail'] + $value['male_gm_fail'])->getColumnDimension('O')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('P' . $slNo, $value['male_CATI_appeared'])->getColumnDimension('P')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('Q' . $slNo, $value['female_CATI_appeared'])->getColumnDimension('Q')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('R' . $slNo, $value['male_CATI_appeared'] + $value['female_CATI_appeared'])->getColumnDimension('R')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('S' . $slNo, $value['male_CATI_pass'])->getColumnDimension('S')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('T' . $slNo, $value['female_CATI_pass'])->getColumnDimension('T')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('U' . $slNo, $value['male_CATI_pass'] + $value['female_CATI_pass'])->getColumnDimension('U')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('V' . $slNo, $value['male_CATI_fail'])->getColumnDimension('V')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('W' . $slNo, $value['female_CATI_fail'])->getColumnDimension('W')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('X' . $slNo, $value['male_CATI_fail'] + $value['male_CATI_fail'])->getColumnDimension('X')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('Y' . $slNo, $value['male_IIA_appeared'])->getColumnDimension('Y')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('Z' . $slNo, $value['female_IIA_appeared'])->getColumnDimension('Z')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AA' . $slNo, $value['male_IIA_appeared'] + $value['female_IIA_appYared'])->getColumnDimension('AA')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AB' . $slNo, $value['male_IIA_pass'])->getColumnDimension('AB')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AC' . $slNo, $value['female_IIA_pass'])->getColumnDimension('AC')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AD' . $slNo, $value['male_IIA_pass'] + $value['female_IIA_pass'])->getColumnDimension('AD')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AE' . $slNo, $value['male_IIA_fail'])->getColumnDimension('AE')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AF' . $slNo, $value['female_IIA_fail'])->getColumnDimension('AF')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AG' . $slNo, $value['male_IIA_fail'] + $value['male_IIA_fail'])->getColumnDimension('AG')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AH' . $slNo, $value['male_IIB_appeared'])->getColumnDimension('AH')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AI' . $slNo, $value['female_IIB_appeared'])->getColumnDimension('AI')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AJ' . $slNo, $value['male_IIB_appeared'] + $value['female_IIB_appeared'])->getColumnDimension('AJ')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AK' . $slNo, $value['male_IIB_pass'])->getColumnDimension('AK')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AL' . $slNo, $value['female_IIB_pass'])->getColumnDimension('AL')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AM' . $slNo, $value['male_IIB_pass'] + $value['female_IIB_pass'])->getColumnDimension('AM')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AN' . $slNo, $value['male_IIB_fail'])->getColumnDimension('AN')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AO' . $slNo, $value['female_IIB_fail'])->getColumnDimension('AO')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AP' . $slNo, $value['male_IIB_fail'] + $value['male_IIB_fail'])->getColumnDimension('AP')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AQ' . $slNo, $value['male_IIIA_appeared'])->getColumnDimension('AQ')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AR' . $slNo, $value['female_IIIA_appeared'])->getColumnDimension('AR')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AS' . $slNo, $value['male_IIIA_appeared'] + $value['female_IIIA_appeared'])->getColumnDimension('AS')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AT' . $slNo, $value['male_IIIA_pass'])->getColumnDimension('AT')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AU' . $slNo, $value['female_IIIA_pass'])->getColumnDimension('AU')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AV' . $slNo, $value['male_IIIA_pass'] + $value['female_IIIA_pass'])->getColumnDimension('AV')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AW' . $slNo, $value['male_IIIA_fail'])->getColumnDimension('AW')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AX' . $slNo, $value['female_IIIA_fail'])->getColumnDimension('AX')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AY' . $slNo, $value['male_IIIA_fail'] + $value['male_IIIA_fail'])->getColumnDimension('AY')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('AZ' . $slNo, $value['male_IIIB_appeared'])->getColumnDimension('AZ')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BA' . $slNo, $value['female_IIIB_appeared'])->getColumnDimension('BA')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BB' . $slNo, $value['male_IIIB_appeared'] + $value['female_IIIB_appBBred'])->getColumnDimension('BB')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BC' . $slNo, $value['male_IIIB_pass'])->getColumnDimension('BC')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BD' . $slNo, $value['female_IIIB_pass'])->getColumnDimension('BD')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BE' . $slNo, $value['male_IIIB_pass'] + $value['female_IIIB_pass'])->getColumnDimension('BE')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BF' . $slNo, $value['male_IIIB_fail'])->getColumnDimension('BF')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BG' . $slNo, $value['female_IIIB_fail'])->getColumnDimension('BG')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BH' . $slNo, $value['male_IIIB_fail'] + $value['male_IIIB_fail'])->getColumnDimension('BH')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BI' . $slNo, $value['male_SC_appeared'])->getColumnDimension('BI')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BJ' . $slNo, $value['female_SC_appeared'])->getColumnDimension('BJ')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BK' . $slNo, $value['male_SC_appeared'] + $value['female_SC_appeared'])->getColumnDimension('BK')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BL' . $slNo, $value['male_SC_pass'])->getColumnDimension('BL')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BM' . $slNo, $value['female_SC_pass'])->getColumnDimension('BM')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BN' . $slNo, $value['male_SC_pass'] + $value['female_SC_pass'])->getColumnDimension('BN')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BO' . $slNo, $value['male_SC_fail'])->getColumnDimension('BO')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BP' . $slNo, $value['female_SC_fail'])->getColumnDimension('BP')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BQ' . $slNo, $value['male_SC_fail'] + $value['male_SC_fail'])->getColumnDimension('BQ')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BR' . $slNo, $value['male_ST_appeared'])->getColumnDimension('BR')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BS' . $slNo, $value['female_ST_appeared'])->getColumnDimension('BS')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BT' . $slNo, $value['male_ST_appeared'] + $value['female_ST_appeared'])->getColumnDimension('BT')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BU' . $slNo, $value['male_ST_pass'])->getColumnDimension('BU')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BV' . $slNo, $value['female_ST_pass'])->getColumnDimension('BV')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BW' . $slNo, $value['male_ST_pass'] + $value['female_ST_pass'])->getColumnDimension('BW')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BX' . $slNo, $value['male_ST_fail'])->getColumnDimension('BX')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BY' . $slNo, $value['female_ST_fail'])->getColumnDimension('BY')->setwidth(10);
$objPHPExcel->getActiveSheet()->setCellValue('BZ' . $slNo, $value['male_ST_fail'] + $value['male_ST_fail'])->getColumnDimension('BZ')->setwidth(10);
$objPHPExcel->getActiveSheet()->getStyle('A' . $slNo . ':BZ'. $slNo)->applyFromArray($styleArray);
$objPHPExcel->getActiveSheet()->getStyle('A' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('B' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
// $objPHPExcel->getActiveSheet()->getStyle('C' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('D' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
// $objPHPExcel->getActiveSheet()->getStyle('E' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('F' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('G' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('H' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('I' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('J' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('K' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('L' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('M' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('N' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('O' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('P' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('Q' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('R' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('S' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('T' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('U' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('V' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('W' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('X' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('Y' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('Z' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AA' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AB' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AC' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AD' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AE' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AF' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AG' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AH' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AI' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AJ' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AK' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AL' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AM' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AN' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AO' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AP' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AQ' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AR' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AS' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AT' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AU' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AV' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AW' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AX' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AY' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('AZ' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BA' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BB' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BC' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BD' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BE' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BF' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BG' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BH' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BI' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BJ' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BK' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BL' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BM' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BN' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BO' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BP' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BQ' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BR' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BS' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BT' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BU' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BV' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BW' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BX' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BY' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
$objPHPExcel->getActiveSheet()->getStyle('BZ' . $slNo)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);
}
$objPHPExcel->getActiveSheet()->setTitle($fileName);
$objPHPExcel->getActiveSheet()->getPageSetup()
->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);
getheaders($objPHPExcel, $fileName);
}
|