delphi5中。报表打印不能换行(字段类型不能为memo)

解决方案 »

  1.   

    AutoSize:=False
    AutoStretch:=True;
    WordWrap:=True;
    //最重要的
    你的该字段的内容里要包含空格或者回车符(在要折行的地方)即#10和#13
      

  2.   

    嘻嘻,字段不能为memo,但你可以赋给一个memo吗,然后再一行一行地读到qrmemo中就行了。
      

  3.   

    TO  Carfield(一只特别懒的猫)
    AutoSize:=False
    AutoStretch:=True;
    WordWrap:=True;
    可以吗?
    换行为什么不自己动态的去写?
    我有写过
      

  4.   

    TO  Carfield(一只特别懒的猫)
    AutoSize:=False
    AutoStretch:=True;
    WordWrap:=True;
    可以吗?
    换行为什么不自己动态的去写?
    我有写过
      

  5.   

    写个函数
    处理一下OK?
    fuction texttomemo(a:string,n:integer):string;
    var tempstr1,tempstr2 ,tempstr3:string;
    tempnum:integer;
    begin
    tempnum:=0;
    tempstr1:=a;
    while length(tempstr1)<>0 do
    begin
    tempstr3:=copy(tempstr1,1,n)
    tempstr2:=tempstr2+tempstr3+#13#10;
    tempstr1:=copy(tempstr1,n,length(tempstr1))
    end;
    result:=tempstr2;
    end;
      

  6.   


    procedure TCommRepForm.QRDBText3Print(sender: TObject; var Value: string);
    var
         x: integer;
         xbytetype: TMbcsByteType;
    begin
         x := 66;
         if length(value) > x then
         begin
              xbytetype := bytetype(value, x);
              if (xbytetype = mbLeadByte) or (xbytetype = mbsinglebyte) then
                   insert(#13, value, x)
              else
                   insert(#13, value, x + 1);
         end;
    end;依此类推!!