Page 1 of 1

Build commandline exe

PostPosted: Mon Oct 24, 2011 10:56 pm
by smartmedia
Hi..

There times where exist a need to build a application that run in DOS mode from commandline, is possible to add this future to NB...???
Of course the commandline exe will only accept switch from commandline and will not have GUI. But it must have a optional help text to show when it runs without switch.
If can be done, can be done quickly..???

Image

Thanks

PostPosted: Mon Oct 24, 2011 11:09 pm
by Tony Kroos
and with smaller filesize if possible

PostPosted: Tue Oct 25, 2011 3:57 am
by HPW
Hm,

You want a commandline tool but the programming capabilitys of neobook.
So the runtime is needed.
And therefor I think you won't get a smaller filesize.

Maybe another wish could work for you:

A new option in F6/Window/Initial window position:

Additional to the current 9 Pos-options a: Out of visible area

Then it would appear out of view and your commanline-code can move it back into visibility when needed.

PostPosted: Tue Oct 25, 2011 4:02 am
by smartmedia
Hi..

Hans, i prefer a clean native solution than alchemies. If the exe comes from native solution will be smaller, i think, i am not sure but always native code are smaller.

PostPosted: Tue Oct 25, 2011 4:27 am
by dec
smartmedia wrote:Hi..

Hans, i prefer a clean native solution than alchemies. If the exe comes from native solution will be smaller, i think, i am not sure but always native code are smaller.


An executable remain smaller if their capabilities are smaller too. For example, with Delphi you can create console executables about 50 KB, but, if you add some kind of features that using certain "units", then increase the final executable size. For example, if you add a "form" on a console application, finally the executable size is similar than a GUI application.

Just to consider. ;)

PostPosted: Tue Oct 25, 2011 4:39 am
by Tony Kroos
imho, to get app smaller the nb-player attached to exe should be totally rewritten without all unnecessary gui stuff... ( it's hard to believe developers will make it come true... besides, it is not a "must-have" suggestion, but maybe some day...

PostPosted: Tue Oct 25, 2011 10:36 am
by Neosoft Support
You want to create DOS applications with NeoBook?

Without a GUI only a small percentage of actions would still function. Very few (if any) plug-ins would work.

PostPosted: Tue Oct 25, 2011 10:45 am
by smartmedia
Hi..

Personally i don't mind about the size but i do mind if some plugin don't play.

PostPosted: Tue Oct 25, 2011 11:14 am
by HPW
Hans, i prefer a clean native solution than alchemies.


Nothing to do with alchemies.
I had only thought about your wishes and the idea to get it with minimal changes to the neobook core.
So I think you do not want a DOS programm, you want a windows console programm without a visible GUI.

So when I set [WindowLeft] to -1000 I see no more GUI.
I asked for the new option to avoid the initial display on screen.
Such a program would process its commandline arguments and terminate itself when ready. For a user similar to a console programm.

PostPosted: Wed Oct 26, 2011 7:21 am
by HPW
A longtime neobook fellow sent me a tip with a workaround:

Goto "Book Properties" and choose "Custom Shaped" and as a mask-image you choose a small bitmap (bmp, 25x25).
And you choose the imagecolor as the maskcolor.
Now the whole image is maskcolor it gets transparent.
You have a app without a GUI.
It does not show anything on startup.

PostPosted: Wed Oct 26, 2011 8:18 am
by smartmedia
Hi..

Hans thanks for your suggestions and if i was rude to you about alchemies. i am sorry. The point is i want to be able to run from console (cmd) the application. And when it runs without any flags to show a list with all possible command and what they do. After all in your suggestion you still have the application open in the task bar, and perhaps some people will think that this application can harm their computer.
Thanks any way, i will keep the tip for the future.

PostPosted: Wed Oct 26, 2011 10:29 am
by dpayer
smartmedia wrote:Hi..

.....The point is i want to be able to run from console (cmd) the application.....


Here is how David from Argentina solves that problem:

http://www.powerbasic.com/products/pbcc/

:)

David P.

PostPosted: Wed Oct 26, 2011 10:38 am
by HPW
David,

There are tons of optional tools (delphi,powerbasic,purebasic,newlisp,pdscript etc.) which could be used.
But he asked for a neobook based solution. ;-)

PostPosted: Wed Oct 26, 2011 6:53 pm
by dpayer
HPW wrote:David,

There are tons of optional tools (delphi,powerbasic,purebasic,newlisp,pdscript etc.) which could be used.
But he asked for a neobook based solution. ;-)


True, he wanted a Neobook solution that had no windows interface and was smaller than the current system provided but still used extensions.

I was just opening a small hole in the box so some thoughts could get out.

I will say this, Neobook is a very easy scripting language to work with and I too have used it as an extension of batch language to get jobs done.

David P.