zoukankan      html  css  js  c++  java
  • cad.net之ACAD和GCAD环境变量获取

    #if AC2006 || AC2007 || AC2008 || AC2009 || AC2010 || AC2011 || AC2012
    
            [System.Security.SuppressUnmanagedCodeSecurity]
    
            [DllImport("acad.exe", CharSet = CharSet.Auto, CallingConvention = CallingConvention.Cdecl, EntryPoint = "acedGetEnv")]//名称大小写不能换
    
            private static extern int AcedGetEnv(string envName, StringBuilder ReturnValue);
    
     
    
            [System.Security.SuppressUnmanagedCodeSecurity]
    
            [DllImport("acad.exe", CharSet = CharSet.Auto, CallingConvention = CallingConvention.Cdecl, EntryPoint = "acedSetEnv")]//名称大小写不能换
    
            private static extern int AcedSetEnv(string envName, StringBuilder NewValue);
    
    #elif AC2013 || AC2014 || AC2015 || AC2016 || AC2017 || AC2018 || AC2019
    
            [System.Security.SuppressUnmanagedCodeSecurity]
    
            [DllImport("accore.dll", CharSet = CharSet.Auto, CallingConvention = CallingConvention.Cdecl, EntryPoint = "acedGetEnv")]//名称大小写不能换
    
            private static extern int AcedGetEnv(string envName, StringBuilder ReturnValue);
    
     
    
            [System.Security.SuppressUnmanagedCodeSecurity]
    
            [DllImport("accore.dll", CharSet = CharSet.Auto, CallingConvention = CallingConvention.Cdecl, EntryPoint = "acedSetEnv")]//名称大小写不能换
    
            private static extern int AcedSetEnv(string envName, StringBuilder NewValue);
    
    #endif
    
     
    
    #if HC2019  //浩辰
    
            [System.Security.SuppressUnmanagedCodeSecurity]
    
            [DllImport("gced.dll", CharSet = CharSet.Auto, CallingConvention = CallingConvention.Cdecl, EntryPoint = "gcedGetEnv")]//名称大小写不能换
    
            private static extern int AcedGetEnv(string envName, StringBuilder ReturnValue);
    
     
    
            [System.Security.SuppressUnmanagedCodeSecurity]
    
            [DllImport("gced.dll", CharSet = CharSet.Auto, CallingConvention = CallingConvention.Cdecl, EntryPoint = "gcedSetEnv")]
    
            private static extern int AcedSetEnv(string envName, StringBuilder NewValue);
    
    #endif
  • 相关阅读:
    python数据结构之字典
    Python数据结构之列表
    使用QrCode生成二维码
    JavaScript在不同环境下的全局对象
    记一次使用 removeEventListener 移除事件监听失败的经历
    Model、View、ViewModel结构以及全局视图模型注入器的说明
    MVVMLight介绍以及在项目中的使用
    WPF/Silverlight深度解决方案:(一)解锁被Storyboard束缚的关联属性
    进程发送消息
    .net4.0中wpf单例启动
  • 原文地址:https://www.cnblogs.com/JJBox/p/10209541.html
Copyright © 2011-2022 走看看