Results 1 to 2 of 2

Thread: Resolution

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Dec 2000
    Location
    Indiana
    Posts
    73

    Resolution

    How do I find out the resolution (current) using API? Thanks
    if(GetWindowLong(hwnd,GWL_ID)==IDC_MICROSOFT_APPLICATION)
    {
    SetWindowText(hwnd,"I suck.");
    SendMessage(hwnd,WM_START_SUCKING,0,0);
    SendMessage(hwnd,WM_CRASH,0,0);
    }

  2. #2
    jim mcnamara
    Guest
    Code:
     long xres,yres;
     xres = GetSystemMetrics(SM_CXSCREEN);
     yres = GetSystemMetrics(SM_CYSCREEN);
     printf("%s %ld %s %ld","Resolution is: ",xres,"by",yres);
    That what you want?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width