/// <summary>
        /// Information sent to this LogTrace will appear on the Design Automation output
        /// </summary>
        public static void LogTrace(string format, params object[] args)
        {
            IGlobal      globalInterface = Autodesk.Max.GlobalInterface.Instance;
            IInterface14 coreInterface   = globalInterface.COREInterface14;
            ILogSys      log             = coreInterface.Log;

            // Note flags are necessary to produce Design Automation output. This is same as C++:
            // SYSLOG_INFO | SYSLOG_IGNORE_VERBOSITY | SYSLOG_BROADCAST
            log.LogEntry(0x00000004 | 0x00040000 | 0x00010000, false, "", string.Format(format, args));
        }
        /// <summary>
        /// Information sent to this LogTrace will appear on the Design Automation output
        /// </summary>
        private static void LogTrace(string format, params object[] args)
        {
            System.Reflection.Assembly a = System.Reflection.Assembly.GetExecutingAssembly();
            string output_msg            = string.Format("DLL {0} compiled on {1}; {2}",
                                                         System.IO.Path.GetFileName(a.Location),
                                                         File.GetLastWriteTime(a.Location),
                                                         string.Format(format, args));

            IGlobal      globalInterface = Autodesk.Max.GlobalInterface.Instance;
            IInterface14 coreInterface   = globalInterface.COREInterface14;
            ILogSys      log             = coreInterface.Log;

            // Note flags are necessary to produce Design Automation output. This is same as C++:
            // SYSLOG_INFO | SYSLOG_IGNORE_VERBOSITY | SYSLOG_BROADCAST
            log.LogEntry(0x00000004 | 0x00040000 | 0x00010000, false, "", output_msg);
        }
Пример #3
0
 public void Debug(string message, string title = "", bool dialog = false)
 {
     _logger.LogEntry(SyslogDebug, dialog, title, FormatLog(message));
 }