using System; using System.Runtime.InteropServices; class Program { [DllImport("blackbox.dll")] extern static int GetHWID(byte[] bytes); static void Main(string[] args) { byte[] buf = new byte[20]; GetHWID(buf); Console.WriteLine(BitConverter.ToString(buf)); } }