Author Topic: Looking for Console command window  (Read 283 times)

Offline rfdes

  • Single posting newcomer
  • *
  • Posts: 1
Looking for Console command window
« on: July 08, 2020, 02:11:10 am »

I'm a casual user of Code Blocks for writing C programs but would like to have the ability of sending direct commands from a 'Dos Box Terminal' window docked within the C:B app.  I've yet been able to determine if this is directly possible with C:B or if there is a plugin available for doing this.  I'm using C:B within Win 10.  Would someone please inform me whether this is doable ?


Offline Pecan

  • Plugin developer
  • Lives here!
  • ****
  • Posts: 2252
Re: Looking for Console command window
« Reply #1 on: July 08, 2020, 06:28:45 pm »
I once did this long ago.
It was not possible to dock the windows console within a c/cpp app, but it was possible to start a hidden console to scrape and insert to the console buffer; then presenting that info to a text window enbedded in the c/cpp app.

It was not easy or entirely stable. I wouldn't try to do it again.

It would be more dependable to allow the user to read and write to a text window, execute the user commands via something like wxExecute("cmd /c whatever") and pipe the stdin/stdout to the text window.
« Last Edit: July 08, 2020, 06:35:58 pm by Pecan »