Author Topic: Console size ?  (Read 2276 times)

0 Members and 1 Guest are viewing this topic.

Offline Fifi

  • Forum Regular
  • Posts: 181
    • View Profile
    • My small QB64 contribution
Console size ?
« on: September 10, 2018, 04:37:11 pm »
Hi all,

I would like to change the default size (lcolumns and rows) of a console prior to run a program into it.

I didn't find any sample to do it.

Any help would be truly appreciated.

T.I.A.
Fifi
« Last Edit: September 10, 2018, 04:50:02 pm by Fifi »
It's better to look like an idiot for a short time while asking something obvious to an expert than pretending to be smart all your life. (C) Me.

FellippeHeitor

  • Guest
Re: Console size ?
« Reply #1 on: September 10, 2018, 04:46:25 pm »
I don't think you can, though. Let's see what the others suggest.

Offline Fifi

  • Forum Regular
  • Posts: 181
    • View Profile
    • My small QB64 contribution
Re: Console size ?
« Reply #2 on: September 10, 2018, 05:00:06 pm »
Hi Fellippe,

Thanx for your answer.

So, should I use another window than the console ?

If so, how could I do that (a tiny sample code would be appreciated using my loan.bas sample with comumn = 120 and rows = 30 but also with the capability to scroll the result up and down).

BTW, I've the same problem to adapt this loan.bas sample into a form with InForm (what kind of container to use fro the result)?

Any help with the InForm version of this sample would be truly appreciated.

T.I.A.
Fifi
It's better to look like an idiot for a short time while asking something obvious to an expert than pretending to be smart all your life. (C) Me.

FellippeHeitor

  • Guest
Re: Console size ?
« Reply #3 on: September 10, 2018, 05:15:49 pm »
With InForm, you could probably have a ListBox control and add each output line to it with the AddItem method.

You can also set the list's AutoScroll property to true, so it'll emulate a console.

That would mimick a console window, and the output would be scrollable.

If you consider the overhead, you'd probably feel it's more reasonable to reformat your output to the default 80x25 of a console window.

Now, to truly take advantage of InForm, you'd design an interface with textbox controls for input and would have the output show in labels after a button was clicked to calculate results. Then it'd be a true GUI app.
« Last Edit: September 10, 2018, 05:26:35 pm by FellippeHeitor »

Offline Petr

  • Forum Resident
  • Posts: 1720
  • The best code is the DNA of the hops.
    • View Profile
Re: Console size ?
« Reply #4 on: September 10, 2018, 05:17:28 pm »
:-D it will TRY something and then...

FellippeHeitor

  • Guest
Re: Console size ?
« Reply #5 on: September 10, 2018, 05:26:55 pm »
:-D it will TRY something and then...

Definitely not the way, Petr.