[TUTORIAL] Unable to Initialise the Graphics in Windowed Mode (Fix)

Moderator: Technical Support Team

Locked
Dungle30
Youth Team Player
Posts: 2
Joined: Wed Aug 18, 2021 7:05 am

[TUTORIAL] Unable to Initialise the Graphics in Windowed Mode (Fix)

Post by Dungle30 »

Problem:
Image

Solution from original post: https://champman0102.co.uk/showthread.p ... post490512

I made an update of a batch script from https://champman0102.co.uk/showthread.p ... post481384

When I clicked it once and it would do it for me automatically following step:
1. Change scaling from 150% to 100%
2. Start CM0102
3. Change scaling from 100% to 150%.

Code: Select all

@ECHO OFF

explorer ms-settings:display
ping -n 2 127.0.0.1 > nul

:VBSDynamicBuild
SET TempVBSFile=%tmp%\~tmpSendKeysTemp.vbs
IF EXIST "%TempVBSFile%" DEL /F /Q "%TempVBSFile%"
ECHO Set WshShell = WScript.CreateObject("WScript.Shell") >>"%TempVBSFile%"
ECHO Wscript.Sleep 500                                    >>"%TempVBSFile%"
[b]ECHO WshShell.SendKeys "{TAB}{TAB}{UP 2}"                 >>"%TempVBSFile%"[/b]
ECHO Wscript.Sleep 500                                    >>"%TempVBSFile%"
ECHO WshShell.SendKeys "%%{F4}"                           >>"%TempVBSFile%"

ECHO WshShell.Run("""C:\Program Files (x86)\Championship Manager 01-02\cm0102.exe""") >>"%TempVBSFile%"
ECHO Wscript.Sleep 500                                    >>"%TempVBSFile%"
CSCRIPT //nologo "%TempVBSFile%"

explorer ms-settings:display
ping -n 2 127.0.0.1 > nul

:VBSDynamicBuild
SET TempVBSFile1=%tmp%\~tmpSendKeysTemp1.vbs
IF EXIST "%TempVBSFile1%" DEL /F /Q "%TempVBSFile1%"
ECHO Set WshShell = WScript.CreateObject("WScript.Shell") >>"%TempVBSFile1%"
ECHO Wscript.Sleep 500                                    >>"%TempVBSFile1%"
[b]ECHO WshShell.SendKeys "{TAB}{TAB}{DOWN 2}"                 >>"%TempVBSFile1%"[/b]
ECHO Wscript.Sleep 500                                    >>"%TempVBSFile1%"
ECHO WshShell.SendKeys "%%{F4}"                           >>"%TempVBSFile1%"
CSCRIPT //nologo "%TempVBSFile1%"

EXIT
Edit the line in bold depending on your zoom. For example for starting at 125% zoom you'll change the UP 2/DOWN 2 to UP 1/DOWN 1

Credit goes to M.C.F.C https://champman0102.co.uk/member.php?u=74858
Locked