示例#1
0
        public Int32 HNC_CrdsSetValue(Int32 type, Int32 ax, Int32 value, Int32 ch, Int32 crds)
        {
            Int32  ret = -1;
            IntPtr ptr = Marshal.AllocHGlobal(HncApi.intSize);

            Marshal.WriteInt32(ptr, value);
            ret = HncApi.HNC_CrdsSetValue(type, ax, ptr, ch, crds, _ClientNo);
            Marshal.FreeHGlobal(ptr);

            return(ret);
        }
示例#2
0
        public Int32 HNC_CrdsSetValue(Int32 type, Int32 ax, Double value, Int32 ch, Int32 crds)
        {
            Int32  ret = -1;
            IntPtr ptr = Marshal.AllocHGlobal(HncApi.doubleSize);

            Marshal.StructureToPtr(value, ptr, true);
            ret = HncApi.HNC_CrdsSetValue(type, ax, ptr, ch, crds, _ClientNo);
            Marshal.FreeHGlobal(ptr);

            return(ret);
        }