|
|
nomainwin ' get the size of the desktop area ' not occupied by the task bar ' or any application side bar struct RECT, _ left as long, _ top as long, _ right as long, _ bottom as long uiAction = _SPI_GETWORKAREA calldll #user32, "SystemParametersInfoA", _ uiAction as ulong, _ uiParam as ulong, _ RECT as struct, _ fWinIni as ulong, _ result as long ' get the coordinates of the rectangle PosLeft = RECT.left.struct PosTop = RECT.top.struct PosRight = RECT.right.struct PosBottom = RECT.bottom.struct ' calculate the maximum window size MaxWindowWidth = PosRight - PosLeft MaxWindowHeight = PosBottom - PosTop ' set the window size WindowWidth = MaxWindowWidth WindowHeight = MaxWindowHeight ' set the window position UpperLeftX = PosLeft + 1 UpperLeftY = PosTop + 1 ' display the window open "Full Screen Window with Task Bar showing" for window as #m #m "trapclose [quit]" wait [quit] close #m end
|