China DOS Union

-- Unite DOS · Advance DOS · Grow DOS --

Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum
DOS stands for freedom, openness and progress. Let us work hard, learn from the openness and GNU spirit of FreeDOS and Linux, and together build and grow a free GNU GPL world!

中国DOS联盟论坛
The time now is 2026-08-12 05:08
中国DOS联盟论坛 » DOS批处理 & 脚本技术(批处理室) » Question about multi-line strings View 843 Replies 2
Original Poster Posted 2009-06-20 04:56 ·  中国 陕西 西安 电信
新手上路
Credits 15
Posts 10
Joined 2008-10-05 12:34
17-year member
UID 127487
Gender Male
Status Offline
For example, if I create a new multi-line string, how do I enter data for multiple different lines?
The help says to use /s:
Specifies a character to use as the separator in a REG_MULTI_SZ data string
If omitted, "\0" is used as the separator.

I tried a few times and still couldn't get it to work. I don't understand it. How can this be solved?

Also, if I want a blank line between 2 lines of data, how can that be done?
Floor 2 Posted 2009-06-20 08:31 ·  中国 吉林 延边朝鲜族自治州 电信
银牌会员
★★★
正在学习中的菜鸟...
Credits 1,039
Posts 897
Joined 2009-03-01 15:34
17-year member
UID 140302
Gender Male
From 在地狱中仰望天堂
Status Offline
Use /d value to specify the value of the new registry entry.

For example, /d "han*ye*gu*xing". If /s is not used, the data will be han*ye*gu*xing.
If "han*ye*gu*xing" /s * is used, the data will be:
han
ye
gu
xing
Here, /s specifies the character used as the separator, and replaces the default \.
If you only use /s without specifying a character, the default \ will be used as the separator.
For example:
/ d "han\ye\gu\xing" /s
Since nothing is specified, the default \ is used as the separator. The data will be:
han
ye
gu
xing
Recent Ratings for This Post ( 1 in total) Click for details
RaterScoreTime
694837333 +1 2009-06-20 08:48
Floor 3 Posted 2009-06-20 08:48 ·  中国 陕西 西安 电信
新手上路
Credits 15
Posts 10
Joined 2008-10-05 12:34
17-year member
UID 127487
Gender Male
Status Offline
Thanks for the explanation. I found that the * can't be left out, otherwise it gives an error......
Also, is it possible to have a blank line between 2 different lines of data?
Forum Jump: