public static sbyte?CursorGetTinyInt(HDFqlCursor cursor) { IntPtr pointer = HDFqlPINVOKE.CursorGetTinyInt(HDFqlCursor.getCPtr(cursor)); if (pointer == IntPtr.Zero) { return(null); } else { char [] value = new char[1]; Marshal.Copy(pointer, value, 0, 1); return((sbyte)value[0]); } }