1. Join Now

    AVForums.com uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Batch files to swap display resolutions - or a better idea instead?

Discussion in 'Desktop & Laptop Computers Forum' started by dancingmatt, Jul 27, 2005.

  1. dancingmatt

    dancingmatt
    Active Member

    Joined:
    Apr 26, 2005
    Messages:
    433
    Products Owned:
    0
    Products Wanted:
    0
    Trophy Points:
    18
    Ratings:
    +13
    Hi

    I've got 2 Flattron monitors and a Sanyo Z3 projector. The monitors are nearly always connected, I only get the projector out for when mates are round, watching a DVD, etc.

    If I want a quick game then I just want to fire it up on a monitor in 1024x768, but if I want to run it on the projector in native 1280x720 then some games (eg Unreal Tournament 2004) require editing an .ini file to enable the resolution to run in widescreen as it's not available from the in-game menu. And then, if I've last played it on a projector but I want to play on a monitor, I have to edit the .ini and put the resolution back to 1024x768 again.

    So does anyone have a bright idea on how I get round this? I'm thinking I might write a couple of batch files for each game, one for playing on the monitor and one for the projector, that swap the .ini file to the one with the correct settings and then launch the game, but if anyone has another solution I'd love to know.

    There must be people out there with the same problem, swapping one display device for another which doesn't support the same resolutions? Or even if you don't have this problem, thanks for any help or ideas you can give,

    Ta

    DM
     
  2. Monty Burns

    Monty Burns
    Well-known Member

    Joined:
    Jul 25, 2005
    Messages:
    3,864
    Products Owned:
    0
    Products Wanted:
    0
    Trophy Points:
    86
    Location:
    Londoner living in Doha, Qatar
    Ratings:
    +139
    Sounds like (as your dealing with Ini's) that a batch file to copy in the resoloution ini you want to use and then call the Exe are the way to go.

    E.g. Desktop shortcut to "Start UT.bat"
    copy 1024.bat to c:\ut\ut.ini (or whatever its called)
    c:\ut\ut.exe
    exit

    and obviously create an 800.ini
    the res's ive picked are just an example.


    If your talking games that use the registry its a very similar process. Set the game up using the res u want to use. Backup the registry portion relating to the game and then double click this before playing the game or use regedit batchfile to apply it for you.

    Best of luck!
     
  3. dancingmatt

    dancingmatt
    Active Member

    Joined:
    Apr 26, 2005
    Messages:
    433
    Products Owned:
    0
    Products Wanted:
    0
    Trophy Points:
    18
    Ratings:
    +13
    Hi Monty

    Cheers for that. Do I need "exit" at the end of the batch file?

    And do you happen to know what the batchfile would need to edit the registry? Does regedit need some parameters to get it to automatically add the file to the registry? Must admit, I hadn't thought of using it for that... good idea...!

    Thanks
    DM
     
  4. Monty Burns

    Monty Burns
    Well-known Member

    Joined:
    Jul 25, 2005
    Messages:
    3,864
    Products Owned:
    0
    Products Wanted:
    0
    Trophy Points:
    86
    Location:
    Londoner living in Doha, Qatar
    Ratings:
    +139
    Exit.

    Hmm good question. I think i mainly used this when exiting one batch file to go back to a calling batch file. It certainly wont hurt though :thumbsup:


    Reg stuff

    Simply setup the program u want to use, extract the registry change thats happened. In my case I will call it test.reg.

    Start UT Projector REG.bat Shortcut

    c:\test.reg (you will be asked to confirm this by dialogue box)
    c:\ut\UT.exe
    exit


    easy!

    There is a way to get rid of the confirm. I had to do it a lot as a network admin but im b*gg*red if i can remember it now :confused: It should be easy for you to find this info out though with our master friend Google :thumbsup:

    Good luck!

    Disclaimer: Although the worst that should happen here is that u screw up your game and need to reinstall that, if u are messing with your registry and **** it right up, dont blame me! :rotfl: Back it ALL up first.
     
  5. dancingmatt

    dancingmatt
    Active Member

    Joined:
    Apr 26, 2005
    Messages:
    433
    Products Owned:
    0
    Products Wanted:
    0
    Trophy Points:
    18
    Ratings:
    +13
    Simple enough - seems to be /s for the "silent" mode.

    Cheers again MontyBurns!

    And if you or anyone else can thing of a different way to do it, I'm open to suggestions if only out of curiosity!

    Ta
    DM
     

Share This Page

Loading...