public static int MAKELONG(int wLow, int wHigh) { int low = (int)LOWORD(wLow); short high = LOWORD(wHigh); int product = 0x00010000 * (int)high; int makeLong = (int)(low | product); return makeLong; }