Auto-Detect Resolution

New to FreeBASIC? Post your questions here.
Post Reply
TurtleProgrammer
Posts: 37
Joined: Jan 26, 2017 7:54

Auto-Detect Resolution

Post by TurtleProgrammer »

Is there a way to Auto-Detect Screen Resolution?
sancho3
Posts: 358
Joined: Sep 30, 2017 3:22

Re: Auto-Detect Resolution

Post by sancho3 »

Boromir
Posts: 463
Joined: Apr 30, 2015 19:28
Location: Oklahoma,U.S., Earth,Solar System
Contact:

Re: Auto-Detect Resolution

Post by Boromir »

TurtleProgrammer wrote:Is there a way to Auto-Detect Screen Resolution?

Code: Select all

dim as integer w,h,depth
Screeninfo w,h,depth

screenres w,h,depth


print "Your screen resolution is "+str(w)+" x "+str(h)
print "Your color depth is "+str(depth)

sleep
Post Reply