安装 Progress 时,系统会提示您输入要使用的数字格式。然后将该信息写入位于安装目录中的名为“startup.pf”的文件(Windows 上默认为 C:\Progress\OpenEdge...)
如果您选择了错误的数字格式,您可以使用任何文本编辑器编辑 startup.pf。它应该看起来像这样:
#This is a placeholder startup.pf
#You may put any global startup parameters you desire
#in this file. They will be used by ALL Progress modules
#including the client, server, utilities, etc.
#
#The file dlc/prolang/locale.pf provides examples of
#settings for the different options that vary internationally.
#
#The directories under dlc/prolang contain examples of
#startup.pf settings appropriate to each region.
#For example, the file dlc/prolang/ger/german.pf shows
#settings that might be used in Germany.
#The file dlc/prolang/ger/geraus.pf gives example settings
#for German-speaking Austrians.
#
#Copy the file that seems appropriate for your region or language
#over this startup.pf. Edit the file to meet your needs.
#
# e.g. UNIX: cp /dlc/prolang/ger/geraus.pf /dlc/startup.pf
# e.g. DOS, WINDOWS: copy \dlc\prolang\ger\geraus.pf \dlc\startup.pf
#
# You may want to include these same settings in /dlc/ade.pf.
#
#If the directory for your region or language does not exist in
#dlc/prolang, please check that you have ordered AND installed the
#International component. The International component provides
#these directories and files.
#
-cpinternal ISO8859-1
-cpstream ISO8859-1
-cpcoll Basic
-cpcase Basic
-d mdy
-numsep 44
-numdec 46
startup.pf 文件的更改是全球性的——它们会影响在这台机器上启动的所有会话。如果您只想更改单个会话,则可以将参数添加到命令行(或快捷方式图标属性)或本地 .pf 文件或该会话正在使用的 ini 文件。
您还可以使用 SESSION 系统句柄以编程方式覆盖代码中的格式:
assign
session:numeric-decimal-point = "."
session:numeric-separator = ","
.
display 123456.999.
(如果这是临时更改,您可能需要考虑保存当前值并恢复它们。)
(对于两种最常见的情况,您也可以使用简写 session:numeric-format = "american"。或 "european"。)