WriteOutput returns true

Very new to Commandbox. Running on Windows, when I try “repl”…

CFSCRIPT-REPL: writeOutput(“anything”)
true

writeoutput only ever returns true. What am I doing wrong?

Thanks (great product idea)

J

Thanks for the responses.

Makes sense and I can live with SystemOutput(), but I noticed that in the CommandBox video (CommandBox) at around 4:20 he uses writeOutput() and gets the data, so wondering if windows specific bug, or some sort of configuration option. (I’ll look up the other thread when I get time)

Unfortunately, writeOutpout() was working “on accident” do to a bug that was actually running every REPL command twice. Once this bug was fixed, it began returning “true” which is technically correct since that is what the function returns.

SystemOutput() might “work”, but is actually bypassing CommandBox entirely and just writing to the system output directly.

Here’s the thing though, if you just want to output text, just don’t use any function at all! For instance, here’s outputting a static string:

‘test’
test

And here’s outputting a variable

myVar = ‘test’
test
myVar
test

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com