Programação WEB
Gostaria de reagir a esta mensagem? Crie uma conta em poucos cliques ou inicie sessão para continuar.

PHP Excel - Apply styles and set cell width and cell height to cell generated dynamically

2 participantes

Ir para baixo

PHP Excel - Apply styles and set cell width and cell height to cell generated dynamically Empty PHP Excel - Apply styles and set cell width and cell height to cell generated dynamically

Mensagem por rafaelsp Dom Jul 19, 2015 6:56 pm

How to apply styles and set cell width and cell height to cell generated dynamically?

rafaelsp

Mensagens : 2
Data de inscrição : 19/07/2015

Ir para o topo Ir para baixo

PHP Excel - Apply styles and set cell width and cell height to cell generated dynamically Empty Re: PHP Excel - Apply styles and set cell width and cell height to cell generated dynamically

Mensagem por Admin Dom Jul 19, 2015 6:58 pm

You can use
Código:
$objWorksheet->getActiveSheet()->getRowDimension('1')->setRowHeight(40);
$objWorksheet->getActiveSheet()->getColumnDimension('A')->setWidth(100);

or define auto-size:
Código:
$objWorksheet->getRowDimension('1')->setRowHeight(-1);

Admin
Admin

Mensagens : 1
Data de inscrição : 19/07/2015
Idade : 35
Localização : SP

https://programacaoweb.directorioforuns.com

Ir para o topo Ir para baixo

PHP Excel - Apply styles and set cell width and cell height to cell generated dynamically Empty Re: PHP Excel - Apply styles and set cell width and cell height to cell generated dynamically

Mensagem por rafaelsp Dom Jul 19, 2015 7:01 pm

Great. It's working for me. Thank you!

rafaelsp

Mensagens : 2
Data de inscrição : 19/07/2015

Ir para o topo Ir para baixo

PHP Excel - Apply styles and set cell width and cell height to cell generated dynamically Empty Re: PHP Excel - Apply styles and set cell width and cell height to cell generated dynamically

Mensagem por Conteúdo patrocinado


Conteúdo patrocinado


Ir para o topo Ir para baixo

Ir para o topo


 
Permissões neste sub-fórum
Não podes responder a tópicos