Terminal Windows in Main-Form
Posted
#1
(In Topic #474)
Trainee
because I need a terminal window for running a command, I would like to ask,
how can I integrate this into a form-tool f.e. like text.aera? Appreciate to hear
from you!
Gamba_Dance
Posted
Guru

Shell output from the Shell or Exec command can be directed to a text area like…
Shell 'ls/home' To TextArea1.Text
Also you can
Shell 'command" For Input Output
And set up a Process_Read() event handler.
Info on how to do this is on the gambas wiki shell help.
Posted
Guru

So…
If all you want is to see the output of a shell command and not type anything then it's very simple.
There are 2 ways.
Simply use the Shell or Exec command using the "To" keyword to direct the output straight to the TextArea object like this…
Or…
Another way is to set up a Read event handler that monitors for read events.
using the As keyword to assign events to a name. (in this case the name "Process")
Like this…
Or do you need something more advanced?
Posted
Guru

BruceSteers is right in what he says but if you do need an example I wrote a program with a Terminal in 7 lines of code that is on the Gambas Farm or available here. There are other examples on the Farm as well.
If you give us a bit more detail of what you are trying to do we could offer better advice.
Posted
Trainee
I think your solutions will fetch my problem. Because I didn't find any
chat-code for Gambas, I wanna integrate a terminal-window with a chat-function,
for using in LAN intranet.
Gamba_Dance
1 guest and 0 members have just viewed this.



