Discussion:
echoing a varible into a file
(too old to reply)
b***@madhatter.com
2010-08-04 23:06:52 UTC
Permalink
Using 4dos I want to do this from within a btm

echo some information %dd > ok

Where upon inspection the literal %dd would be in ok in the form of:

Some information %dd.

After trying several ideas it still does not work. I understand the
logic, sort of, why it doesn't in the form above. But there must be some
way to do it?

Part of the btm adds text strings to a file and I want to include %dd as
one part of the string.
Steve Fabian
2010-08-05 12:33:48 UTC
Permalink
***@madhatter.com wrote:
| Using 4dos I want to do this from within a btm
|
| echo some information %dd > ok
|
| Where upon inspection the literal %dd would be in ok in the form of:
|
| Some information %dd.
|
| After trying several ideas it still does not work. I understand the
| logic, sort of, why it doesn't in the form above. But there must be
| some way to do it?
|
| Part of the btm adds text strings to a file and I want to include %dd
| as one part of the string.

Apparently what you want to do is to use ECHO with the desired output
containing the percent (%) character. Two simple methods, both documented in
HELP: 1/ use two consecutive perent signs:
echo some information %%dd > ok
2/ Precede the special character with your 4DOS escape character (default:
ctl-X) or its symbolic representation (%=):

echo some information %=%dd > ok
--
HTH, Steve
b***@madhatter.com
2010-08-05 15:42:08 UTC
Permalink
| Part of the btm adds text strings to a file and I want to include %dd
| as one part of the string.

"Apparently what you want to do is to use ECHO with the desired output
containing the percent (%) character. Two simple methods, both
documented in HELP: 1/ use two consecutive perent signs:
echo some information %%dd > ok 2/ Precede the special character
with your 4DOS escape character (default: ctl-X) or its symbolic
representation (%=):

echo some information %=%dd > ok"

Yes, thanks. I could have sworn I tried the double "%%", but must have
been mistaken.

For finding details the help does not serve as well as an all in one
manual, in my opinion. Text searches of the latter much easier and
quicker it seems to me and often useful in context with similar
information . I have one from a few versions before the one I use so it
provides 95 percent of the information.

Thanks again.

Loading...