我用一个函数wirteln输出多行html代码。请问用一个witeln()函数怎样换行输出?请各位大虾指教。

解决方案 »

  1.   

    怎么你的机子wirteln出来的字符都是连起来的吗?要不你就想写到一个么memo中,最后在savetofile,比你的那个好像还快一点。
      

  2.   

    writeln只能写到行结束符处,所以我觉得是不能用一次writeln函数就写出多行代码的。
      

  3.   

    试试使用#13分割换行,不知道行不行,whriteln('<html><hade></head><body>'+#13+
             'hello, world</body></html>');
      

  4.   

    楼上的改为:
    whriteln('<html><hade></head><body>'+#13#10+
             'hello, world</body></html>');
      

  5.   

    错了,不是输出的代码,是delphi的代码,一行的能否写成两行。
      

  6.   

    直接按 Enter键就可以例如:   label1.caption:=label2.caption
                     +label3.caption;
      

  7.   

    str:string;
    str:='1234546'+#13#10+'789'
    writeln(str)
      

  8.   

    to  SmallHand(火龍) 
    直接回车好象不行
      

  9.   

    to XXSingle(水连天)
     你的方法是吧一行分成几行来写,我的意思是一行代码能不能写成两行,中间用什么连接符连接。
      

  10.   

    to wzds2000()
    writeln(mytextfile,'<tr><td background="images/nav_bg_02.gif" height="21" valign="bottom"><a href="info.htm">Brief Introduction</a></td></tr>');
    比这个还要长,用一个writeln语句写,不要加变量。
      

  11.   

    在我的印象里,writeln好像不能换成两行写,必须写到行结束符。
    真要是有什么好的方法我也不知道了,对不起没帮上忙。
      

  12.   

    to wzds2000()
    没关系,下次在帮忙,谢谢!
      

  13.   

    html里面是不使用</B>来回车啊
      

  14.   

    writeln(mytextfile,'<tr><td background="images/nav_bg_02.gif" height="21" valign="bottom"><a href="info.htm">Brief Introduction</a></td></tr>');
    改成:
    writeln(mytextfile,'<tr><td background="images/nav_bg_02.gif" height="21" '+
            'valign="bottom"><a href="info.htm">Brief Introduction</a></td></tr>');