CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 5 of 5
  1. #1
    Join Date
    Oct 2002
    Posts
    44

    scroll the console

    In windows 2000 and XP, the console window scrolls, can this functionality be added to a program so the console scrolls when the .exe is run under Win 95 and Win 98

  2. #2
    Join Date
    May 2000
    Location
    Washington DC, USA
    Posts
    715

    Yes..

    In a word... yes.

    What you have to do is edit the properties of the command session. Go to the System menu -> properties menu item. Increase the buffer size and if your screen size is less than the buffer size then the scroll bar will appear automajically.

    Remember the properties you're changing are actually stored in a .pif file associated with that cmd.exe file. So if you're programatically openning the command session you'll want to be sure that the cmd.exe file and/or the associated .pif file ( usually called cmd.pif or command.pif are in your execution directory else the first one found on the path will be used.

    If you have any troubles re-post and well help you out.

  3. #3
    Join Date
    Oct 2002
    Posts
    44

    scroll the console redux

    Thanks for your quick reply. I had a look and found the buffer data as you indicated. I'm working in Win XP and want the console to be compatable with Win 95/98. The buffer settings were sufficient in XP but, no scroll bar in 98. Where do I find the associated .pif file you mentioned. I searched and turned up nothing. Thanks

  4. #4
    Join Date
    Jun 2002
    Location
    Letchworth, UK
    Posts
    1,020
    On windows 9x, the only console sizes are 25, 43 and 50. You can set them using the mode command, eg

    mode con: lines=50

    You can't set them any bigger than that: it is just a hangover from the DOS days.
    Succinct is verbose for terse

  5. #5
    Join Date
    Oct 2002
    Posts
    44
    Okay cup but will it scroll in Win9x?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured