Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ Library : Other (not classified elsewhere) » is there a TerminalCtrl?
is there a TerminalCtrl? [message #48983] Fri, 17 November 2017 23:20 Go to next message
forlano is currently offline  forlano
Messages: 1182
Registered: March 2006
Location: Italy
Senior Contributor
Hello,

do we have a TerminalCtrl? I am afraid we do not have one in which to type command of the current operative system.

My problem is the following. My Upp program is just a driver of a console program. Now I run it calling the Windows method CreateProcess(...). Unfortunately I must call that external program as if I were within a given directory... that I cannot set because there is no terminal Confused
Is there a way to simulate at runtime a sort of

cd C:\some_folder
and then execute the command?

Thanks,
Luigi

PS: this console program is HUGO, a static web generator. I am trying to make a trivial front end with a TreeCtrl and a CodeEditor.

[Updated on: Fri, 17 November 2017 23:21]

Report message to a moderator

Re: is there a TerminalCtrl? [message #48984 is a reply to message #48983] Fri, 17 November 2017 23:26 Go to previous messageGo to next message
Oblivion is currently offline  Oblivion
Messages: 1091
Registered: August 2007
Senior Contributor
Quote:
Hello,

do we have a TerminalCtrl? I am afraid we do not have one in which to type command of the current operative system.

My problem is the following. My Upp program is just a driver of a console program. Now I run it calling the Windows method CreateProcess(...). Unfortunately I must call that external program as if I were within a given directory... that I cannot set because there is no terminal Confused
Is there a way to simulate at runtime a sort of

cd C:\some_folder
and then execute the command?

Thanks,
Luigi

PS: this console program is HUGO, a static web generator. I am trying to make a trivial front end with a TreeCtrl and a CodeEditor.


Hello Luigi,

From your description, you seem to be looking for LocalProcess, and its global functions:

https://www.ultimatepp.org/src$Core$AProcess$en-us.html (See the end of the doc. Sys() command may be what you are looking for.)
And
You may want to use it with https://msdn.microsoft.com/en-us/library/windows/desktop/aa3 65530(v=vs.85).aspx on windows.
Best regards,
Oblivion


[Updated on: Fri, 17 November 2017 23:34]

Report message to a moderator

Re: is there a TerminalCtrl? [message #48985 is a reply to message #48984] Fri, 17 November 2017 23:42 Go to previous messageGo to next message
forlano is currently offline  forlano
Messages: 1182
Registered: March 2006
Location: Italy
Senior Contributor
Oblivion wrote on Fri, 17 November 2017 23:26

Hello Luigi,

From your description, you seem to be looking for LocalProcess, and its global functions:

https://www.ultimatepp.org/src$Core$AProcess$en-us.html (See the end of the doc. Sys() command may be what you are looking for.)
And
You may want to use it with https://msdn.microsoft.com/en-us/library/windows/desktop/aa3 65530(v=vs.85).aspx on windows.
Best regards,
Oblivion


Hello Oblivion,

you are right, SetCurrentDirectory( folder_path ) did the trick.
Later I'll inquire the localprocess method hoping to gather the output made by the problem.

Thanks and best regards,
Luigi
Re: is there a TerminalCtrl? [message #48987 is a reply to message #48985] Sat, 18 November 2017 19:55 Go to previous messageGo to next message
forlano is currently offline  forlano
Messages: 1182
Registered: March 2006
Location: Italy
Senior Contributor
Yes, the Sys() command is from far much better.

Luigi
Re: is there a TerminalCtrl? [message #49795 is a reply to message #48987] Tue, 08 May 2018 04:32 Go to previous message
mayduavongts is currently offline  mayduavongts
Messages: 2
Registered: May 2018
Location: Viet Nam
Junior Member
I agree with u!
Previous Topic: draganddrop does not work
Next Topic: click on a checkbox does not work , it does something else
Goto Forum:
  


Current Time: Fri Mar 29 10:07:36 CET 2024

Total time taken to generate the page: 0.01320 seconds