Maybe you need to #include something to get the BYTE data type? check out MSDN