chr(13) 和 chr(10) 的区别 [英] Difference between chr(13) and chr(10)

查看:32
本文介绍了chr(13) 和 chr(10) 的区别的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Crystal Reports中chr(13)chr(10)有什么区别?

What is the difference between chr(13) and chr(10) in Crystal Reports?

我知道 chr(13) 被用作换行符.但我们的一份报告使用了这一行:

I know chr(13) is used as a line break. But one of our reports uses this line:

{Address1} + chr(13) + chr(10) + {Address2}

推荐答案

Chr(10) 是换行符 Chr(13) 是回车符.

Chr(10) is the Line Feed character and Chr(13) is the Carriage Return character.

可能如果您只使用其中一种,您可能不会注意到差异,但您可能会发现自己处于仅使用一种或另一种无法正确显示输出的情况.所以两者都包含会更安全.

You probably won't notice a difference if you use only one or the other, but you might find yourself in a situation where the output doesn't show properly with only one or the other. So it's safer to include both.

从历史上看,换行会向下移动一行,但不会返回到第 1 列:

Historically, Line Feed would move down a line but not return to column 1:

This  
    is  
        a  
            test.

类似的回车会返回到第 1 列,但不会向下移动一行:

Similarly Carriage Return would return to column 1 but not move down a line:

This  
is  
a  
test.

将其粘贴到文本编辑器中,然后选择显示所有字符",您会看到这两个字符出现在每行的末尾.安全总比后悔好.

Paste this into a text editor and then choose to "show all characters", and you'll see both characters present at the end of each line. Better safe than sorry.

这篇关于chr(13) 和 chr(10) 的区别的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆