Fortes Report

Delphi

24/10/2006

Pessoal, estou com um problema para trocar uma propriedade em tempo de execução!

Tenho o seguinte código:

if rgOrientacao.ItemIndex = 0
then rlReport.PageSetup.Orientation := poPortrait
else rlReport.PageSetup.Orientation := poLandscape;

Que me gera o seguinte erro na hora de compilar:

Incompatible types ´TRLPageOrientation´ and ´TPrinterOrientation´

alguém sabe como posso resolver?

vlw


Abdigadiga

Abdigadiga

Curtidas 0

Respostas

Tnaires

Tnaires

24/10/2006

Olá
Simples: as constantes poOrientation e poLandscape, do tipo TPrinterOrientation, estão definidas na unit Printers, e também estão definidas na unit RLTypes, sob o tipo TRLPageOrientation.
Basta você substituir a declaração da unit Printers pela unit RLTypes na instrução [b:48e736ed9e]uses[/b:48e736ed9e] da unit.


GOSTEI 0
Abdigadiga

Abdigadiga

24/10/2006

vlw!

^_^


GOSTEI 0
Rpaiola

Rpaiola

24/10/2006

Valeu, funciona mesmo ! obrigado.


GOSTEI 0
POSTAR