using System; using System.Reflection; using System.Diagnostics; namespace ConsoleApplication1 { /// <summary> /// Summary description for Class1. /// </summary> class Class1 { /// <summary> /// The main entry point for the application. /// </summary> [STAThread] static void Main(string[] args) { DebuggableAttribute dbg = (DebuggableAttribute)Attribute.GetCustomAttribute( System.Reflection.Assembly.GetExecutingAssembly(), typeof(DebuggableAttribute)); if (dbg != null) Console.WriteLine("Debug Mode"); else Console.WriteLine("Release Mode"); } } }Regards