Joe Strazzere - All Things Quality

Visit my new blog at http://strazzere.blogspot.com/


December 1, 2005 - WinTask - GetColors

Posted in WinTask

'
' GetColors
'

dim dc as unsigned
dim bpp as unsigned

dc=External("user32","GetDC",0)

bpp=External("gdi32","GetDeviceCaps",dc,12)

ret=External("user32","ReleaseDC",0,dc)

msgbox("We are displaying "+str$(bpp)+" bits per pixel")

Select Case bpp
  Case 4
    MsgBox("That's 16 colors")
  Case 8
    MsgBox("That's 256 colors")
  Case 16
    MsgBox("That's 65536 colors")
  Case 24
    MsgBox("That's 16777216 colors")
  Case Else
    MsgBox("That's True Color")
EndSelect


<- Last Page :: Next Page ->

About Me

A gathering place for information and ideas about Quality Assurance, Testing, and other useful topics.

Problems cannot be solved by the same level of thinking that created them. - A. Einstein

Search This Site

Translate This Site

RSS Feed

Subscribe

Twitter

@jstrazzere

Categories

Life
QA
Sports
Tools
WinTask
Work in General

What I'm Reading Now