prompt with a numeric message identifier

Discussions about editing and cleaning data
Forum rules
New release: CSPro 8.0
Post Reply
AriSilva
Posts: 591
Joined: July 22nd, 2016, 3:55 pm

prompt with a numeric message identifier

Post by AriSilva »

The help says that the prompt accepts a message, but it cannot be from the message file.
That is,
prompt(500, password);
where
Message file
500 Type your password
It issues a compiler error message
Best
Ari
Gregory Martin
Posts: 1777
Joined: December 5th, 2011, 11:27 pm
Location: Washington, DC

Re: prompt with a numeric message identifier

Post by Gregory Martin »

The helps say "showing the string expression message." Except for the errmsg/maketext/... group of functions, which can take a string or a number, all other CSPro functions require strings. The shortest workaround for that is the tr function:
prompt(tr(500), password);
Post Reply