Yo, trabaje de otra manera:
Creo las columnas en runtime con un ciclo (for i := 0 to q.FieldsCount-1)
Este el el código base para hacerlo:
Código Delphi
[-]
With TQRDBText.Create(AOwner) do
begin
Parent := AOwner; Height := AltoStd;
Top := 1;
Left := PxCampo; ParentFont := True;
AutoSize := False;
Width := ElAncho; DataSet := Self.DataSet; DataField := ElCampo; Tag := ElTag; OnPrint := QRDBTextPrint; WordWrap := False;
Alignment := Alineacion;
If Bold Then
Font.Style := [fsBold];
If DataSet.FieldByName(ElCampo) is TFloatField Then
Begin
Alignment := taRightJustify;
Mask := '#,##0.00'; End;
End;
PXCampo := PxCampo + ElAncho + Separacion; end;