Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. How to set display resolution

How to set display resolution

Scheduled Pinned Locked Moved C / C++ / MFC
tutorialquestion
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    reza matinnejad
    wrote on last edited by
    #1

    How to set display resolution (800*600,1024*...) in runtime?

    P V 2 Replies Last reply
    0
    • R reza matinnejad

      How to set display resolution (800*600,1024*...) in runtime?

      P Offline
      P Offline
      prasad_som
      wrote on last edited by
      #2

      Use ChangeDisplaySettings. Refer this article by maciejr[^]

      Prasad Notifier using ATL | Operator new[],delete[][^]

      1 Reply Last reply
      0
      • R reza matinnejad

        How to set display resolution (800*600,1024*...) in runtime?

        V Offline
        V Offline
        vibindia
        wrote on last edited by
        #3

        DEVMODE ESimSetDM; EnumDisplaySettings (NULL, ENUM_CURRENT_SETTINGS, &ESimSetDM); if( (ESimSetDM.dmPelsWidth != 800) || ( ESimSetDM.dmPelsHeight != 600)) { ESimSetDM.dmPelsWidth = 800; ESimSetDM.dmPelsHeight = 600; ChangeDisplaySettings( &ESimSetDM,CDS_UPDATEREGISTRY ); } this code will always keep the Display settings as 80*600:->

        VIBIN "Fool's run away,where angle's fear to tread"

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups