Issue
I have a cell with multiple Link
+---------+---------+
| | |
| Cell 1 | Cell 2 |
| | |
+---------+---------+
| | Link 1 |
| ROW 1 | Link 2 |
| | Link 3 |
+---------+---------+
how can I make this with phpExcel ? I know below code can set hyperlink to a cell but i don't know how can set multiple link to a cell!
$objPHPExcelExport->setActiveSheetIndex(0)
->setCellValue('A'.$index, $row)
->setCellValue('B'.$index, $link);
$objPHPExcelExport->getActiveSheet()
->getCell('B'.$index)
->getHyperlink()
->setUrl('http://'.$url);
Solution
I'm not aware that you can.... how would you do it in MS Excel? As far as I know, MS Excel allows a single link for the cell, not links for indivdual text blocks within that cell.
Even using MS Excel's HYPERLINK() function, and creating a concatenated string combining all the links
=HYPERLINK("http://www.google.co.uk","GOOGLE")&CHAR(10)&HYPERLINK("http://www.amazon.co.uk","AMAZON")
doesn't achieve your objective.
So I don't beleive that what you want to do can be achieved in MS Excel; an if MS Exel doesn't allow it, then nor will PHPEexcel
Answered By - Mark Baker Answer Checked By - Timothy Miller (PHPFixing Admin)
0 Comments:
Post a Comment
Note: Only a member of this blog may post a comment.