Is there a way to hide shell console in a program that runs under shell

189 views
Skip to first unread message

Nicolas Escribal

unread,
Jan 30, 2015, 10:44:44 AM1/30/15
to haxe...@googlegroups.com
Hi,

I'm trying to run a program from haxe (mplayer.exe) to be more accurate using sys.io.Process.
When I create the process in Windows it opens a command shell and then the program.
I would like to run the program but without the console and I need to communicate with the process to send commands (this is why I can't use other programs to hide the console like createHiddenConsole or CHP).
I believe C++ has an option in process creation to hide the shell. Is there a way in haxe to do this?

Thanks in advance.

Yaroslav Sivakov

unread,
Jan 31, 2015, 6:25:59 AM1/31/15
to haxe...@googlegroups.com
You can try hant library:
new hant.Process("mplayer.exe", [args], hant.Process.SW_HIDE, true)

Nicolas Escribal

unread,
Jan 31, 2015, 9:04:20 AM1/31/15
to haxe...@googlegroups.com

Thanks a lot! ... I'll try it.

--
To post to this group haxe...@googlegroups.com
http://groups.google.com/group/haxelang?hl=en
---
You received this message because you are subscribed to a topic in the Google Groups "Haxe" group.
For more options, visit https://groups.google.com/d/optout.

Nicolas Escribal

unread,
Feb 2, 2015, 9:57:08 AM2/2/15
to haxe...@googlegroups.com
Hi,

That's exactly what I need, I tryed hant but it doesn't work on native c++ for Windows platform.
Looks like it works only for neko? Is it possible to add the support to hant for native c++ for Windows?

Thanks in advance.

Yaroslav Sivakov

unread,
Feb 2, 2015, 10:09:58 AM2/2/15
to haxe...@googlegroups.com
Hello! Sorry, cpp in not supported (just I never use haxe/cpp). I think for developer, who know haxe/cpp, adding cpp support in not too difficult.

02.02.2015 17:57, Nicolas Escribal пишет:
--

Nicolas Escribal

unread,
Feb 2, 2015, 10:38:34 AM2/2/15
to haxe...@googlegroups.com
Hi Yaroslav.

I'm trying to clone repo to try to add cpp support but it raises me an error saying that https://nesc...@bitbucket.org/yar3333/haxe-hant is not a valid repository.
Could it be some permission setting?

Thanks!

Yaroslav Sivakov

unread,
Feb 2, 2015, 10:46:47 AM2/2/15
to haxe...@googlegroups.com
There is no access limits.

Ensure you try command (without user name):
    hg clone https://bitbucket.org/yar3333/haxe-hant

Also, you can try click a "Fork" to fork you own copy before cloning to local.

Nicolas Escribal

unread,
Feb 2, 2015, 10:50:28 AM2/2/15
to haxe...@googlegroups.com
Sorry, I had disabled mercurial from my Source Tree.

i will try to add cpp support and I will let you know.

Thanks!

Nicolas Escribal

unread,
Feb 2, 2015, 4:27:03 PM2/2/15
to haxe...@googlegroups.com
I couldn't build it ... any suggestion?

Yaroslav Sivakov

unread,
Feb 3, 2015, 2:13:44 PM2/3/15
to haxe...@googlegroups.com
Too few information... To build just run
make
from the "build" directory.

What errors you see?
Reply all
Reply to author
Forward
0 new messages