Problem with executeCommandLine in Rules

I try to run the program balabolka_console.exe in rules:
executeCommandLine( “c:/balabolka/balabolka_console.exe -t some text”)
Does not work! Тo error logs.

I run from the command line c:/balabolka/balabolka_console.exe -t some text
So works and say “some text”

Why does not work in the rules?

Could you supply the log entries it gave you? Which version of openHAB are you using?

Change your call to the following:

val results = executeCommandLine("c:/balabolka/balabolka_console.exe -t some text", 5000)
logInfo("Exec", "Results from balabolka:\n" + results)

Then check the logs for what your executable is returning. There may be an error and this is the only way to see that error.

1 Like

After normal execution in openhab.log:
2016-02-10 13:46:30.720 [INFO ] [g.openhab.io.net.exec.ExecUtil] - executed commandLine ‘c:/balabolka/balabolka_console.exe -t Внимание’

And with control error in openhab.log:
2016-02-10 13:52:16.691 [INFO ] [org.openhab.model.script.Exec ] - Results from balabolka:
No errors…

I use OH 1.8.1
On PIPO X8 Windows 10

Logs written below. No error in the logs.

I found problem:
balabolka_console.exe works fine with OH 1.8.1 on Windows 7
but it’s not working with OH 1.8.1 on Windows 10…