当前位置: 首页>>代码示例>>C#>>正文


C# Log.Show方法代码示例

本文整理汇总了C#中Log.Show方法的典型用法代码示例。如果您正苦于以下问题:C# Log.Show方法的具体用法?C# Log.Show怎么用?C# Log.Show使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Log的用法示例。


在下文中一共展示了Log.Show方法的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: window

        public window()
        {
            mParser = new Parser(this);
            InitializeComponent();
            //mParticipants = new ParticipantList();
            mLog = new Log();
            this.StartPosition = FormStartPosition.CenterScreen;
            //mParticipants.Top = this.Top;
            //mParticipants.Left -= (this.Left - this.Width - 20);
            //mParticipants.Show();

            mLog.Top = this.Top;
            mLog.Left += (this.Left + this.Width + 20);
            mLog.Show();
        }
开发者ID:sanchaz,项目名称:PADITable,代码行数:15,代码来源:Form1.cs

示例2: StartButton_Click

 private void StartButton_Click(object sender, RoutedEventArgs e)
 {
     AppSetting.Default.WorkCollection = int.Parse(this.TextBox1.Text);
     AppSetting.Default.VirtualMemory = int.Parse(this.TextBox2.Text);
     AppSetting.Default.PhysicMemory = int.Parse(this.TextBox3.Text);
     AppSetting.Default.GenerateProcessTimeLimit = int.Parse(this.TextBox4.Text);
     AppSetting.Default.ReadDataTimeLimit = int.Parse(this.TextBox5.Text);
     AppSetting.Default.ProcessExpirationTimeLimit = int.Parse(this.TextBox6.Text);
     AppSetting.Default.SimulationTimeLimit = int.Parse(this.TextBox7.Text);
     AppSetting.Default.VirtualPagePerProcess = int.Parse((this.TextBox8.Text));
     AppSetting.Default.AllPageFold = 0;
     AppSetting.Default.PageFoldCounter = 0;
     AppSetting.Default.Save();
     source.OperatingSystem os = new source.OperatingSystem();
     Log logwindow = new Log();
     AppSetting.Default.log = logwindow.TextBox;
     logwindow.Show();
     os.BeginSimulation();
 }
开发者ID:pashchuk,项目名称:OS-Labs,代码行数:19,代码来源:MainWindow.xaml.cs

示例3: menuHelp_Log_Click

 private void menuHelp_Log_Click(object sender, EventArgs e)
 {
     Log form = new Log();
     try
     {
         form.Show(this);
     }
     catch
     {
         Log.Write("Log instance error", this.Name, "menuHelp_Log_Click", Log.LogType.ERROR);
     }
 }
开发者ID:dmarijanovic,项目名称:uber-tools,代码行数:12,代码来源:Main.cs

示例4: Form_operator_Load

        private void Form_operator_Load(object sender, EventArgs e)
        {
            test = new Test(this);
            this.Location = new Point((screen.X / 2) - (this.Width / 2), (screen.Y / 2) - (this.Height / 2) - 150);

            form2 = new Form_car_number(this);
            form2.Show();
            formC = new Form_close(this);
            formC.Show();
            L = new Log(this);
            L.Show();
            textBox_price.Text = price.GetData().Rows[0]["price"].ToString();
            Price.changePrice(double.Parse(textBox_price.Text));
        }
开发者ID:Serious-PO,项目名称:Serious-parking,代码行数:14,代码来源:Form_operator.cs

示例5: log_Click

        // start logging
        private void log_Click(object sender, EventArgs e)
        {
            _log = new Log();
            _log.Show();
            _log.setTuner(this);

            if (WebServerEnabled)
            {
               _webserver.Logger = _log;
               _webserver.LogEnabled = true;
            }
        }
开发者ID:dbulling,项目名称:Pandora-Keys,代码行数:13,代码来源:Tuner.cs

示例6: button1_Click

 private void button1_Click(object sender, EventArgs e)
 {
     if (!logShown)
     {
         Log form = new Log();
         form.Show();
         logShown = true;
     }
 }
开发者ID:Alister742,项目名称:ParseKit,代码行数:9,代码来源:Main.cs

示例7: ViewLog_Click

 private void ViewLog_Click(object sender, EventArgs e)
 {
     if (m_log == null)
     {
         m_log = new Log();
         m_log.Location = m_log_location;
         m_log.FormClosed += Log_FormClosed;
         m_log.MdiParent = this;
         m_log.Show();
     }
     else if (m_log.WindowState == FormWindowState.Minimized)
         m_log.WindowState = FormWindowState.Normal;
 }
开发者ID:x893,项目名称:cantact-fw,代码行数:13,代码来源:CANtactGui.cs

示例8: button1_Click

 private void button1_Click(object sender, EventArgs e)
 {
     if (uid.TextLength == 0)
     {
         MessageBox.Show("Please enter your username.","Universal Market Trading System");
     }
     else if (pid.TextLength == 0)
     {
         MessageBox.Show("Please enter your password.", "Universal Market Trading System");
     }
     else if (rid.TextLength == 0)
     {
         MessageBox.Show("Please enter the round number.", "Universal Market Trading System");
     }
     else if (!IsNumeric(rid.Text))
     {
         MessageBox.Show("Please enter a NUMBER.", "Universal Market Trading System");
     }
     else
     {
         if (Loginx(uid.Text, pid.Text).Contains("Back") == false)
         {
             if (roundx(rid.Text).Contains("Error") == false)
             {
                 UMTS umts = new UMTS();
                 umts.Text += namex(rid.Text);
                 umts.Show();
                 UMTS.round = rid.Text;
                 UMTS.cc = ccc;
                 Log log = new Log();
                 log.Show();
                 this.Visible = false;
             }
             else
             {
                 MessageBox.Show("The system could not log in. Please try again.", "Universal Market Trading System");
             }
         }
         else
         {
             MessageBox.Show("The system could not log in. Please try again.", "Universal Market Trading System");
         }
     }
 }
开发者ID:0aix,项目名称:Programming-Sources,代码行数:44,代码来源:Login.cs

示例9: btnLog_Click

 //Metode som åpner log formen som skal vise log som blir skrevet i Logger klasse.
 private void btnLog_Click(object sender, EventArgs e)
 {
     if (logForm == null)
     {
         logForm = new Log();
         logForm.StartPosition = FormStartPosition.Manual; // Velger å sette startposisjonen til dette formet manuelt
         logForm.Location = new Point(700, 40);//Startpossisjonen til formen er i det pointe(x,y)
         logForm.Show();
     }
     else
     {
         logForm.Focus();
     }
 }
开发者ID:RepublicOfProgrammers,项目名称:polakken,代码行数:15,代码来源:Gui.cs

示例10: showLog_Click

 private void showLog_Click(object sender, EventArgs e)
 {
     Log f2 = new Log();
     f2.Show();
 }
开发者ID:Adios,项目名称:RTMPExploreX,代码行数:5,代码来源:Main.cs

示例11: viewLogToolStripMenuItem_Click

 private void viewLogToolStripMenuItem_Click(object sender, EventArgs e)
 {
     Log = new Log(DataAccess);
     Log.Show();
 }
开发者ID:jonathanargo,项目名称:ClockIn,代码行数:5,代码来源:MainForm.cs

示例12: btnLog_Click

 private void btnLog_Click(object sender, EventArgs e)
 {
     Log log = new Log();
     log.Show();
 }
开发者ID:stamlercas,项目名称:acutwist,代码行数:5,代码来源:Dashboard.cs

示例13: Main

        static void Main(string[] args)
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            Log.SaveLocal = true;
            Log log = new Log();
            log.Show();
            Log.Write(new string[] { "Starting " + Application.ProductName, "Version: " + Application.ProductVersion, "Path: " + Application.ExecutablePath }, typeof(Program), "Main", Log.LogType.DEBUG);
            Log.Write(args, typeof(Program), "Main", Log.LogType.DEBUG);
            string putanja = Application.StartupPath;
            if (!putanja.EndsWith("\\"))
                putanja += "\\";

            // If this application ends with upd then this is new update temperaly application
            if (Application.ExecutablePath.ToLower().EndsWith("upd.exe"))
            {
                try
                {
                    // Weith for old application to exit
                    Thread.Sleep(1000);
                    // Delete old application
                    if (File.Exists(putanja + "AutoUpdate.exe"))
                    {
                        File.Delete(putanja + "AutoUpdate.exe");
                        Log.Write("Delete AutoUpdate.exe", typeof(Program), "Main", Log.LogType.DEBUG);
                    }
                    // Copy self as new application
                    File.Copy(putanja + "autoupdateupd.exe", putanja + "AutoUpdate.exe");
                    Log.Write(new string[] { "Copy from: " + putanja + "autoupdateupd.exe", "Copy to: " + putanja + "AutoUpdate.exe" }, typeof(Program), "Main", Log.LogType.DEBUG);

                    // Start new application
                    string org_args = "";
                    foreach (string arg in args)
                    {
                        org_args += " " + arg;
                    }
                    System.Diagnostics.Process process = System.Diagnostics.Process.Start(putanja + "AutoUpdate.exe", org_args);
                    // If process is not null new application is started, then exit this application
                    if (process != null)
                    {
                        Log.Write("Exit autoupdateupd.exe", typeof(Program), "Main", Log.LogType.DEBUG);
                        Application.Exit();
                    }
                }
                catch (Exception ex)
                {
                    Log.Write(ex, typeof(Program), "Main", Log.LogType.ERROR);
                    MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
                }
            }
            else
            {
                // Entering normal application, delete if new update application exists
                try
                {
                    if (File.Exists(putanja + "AutoUpdateUPD.exe"))
                    {
                        File.Delete(putanja + "AutoUpdateUPD.exe");
                        Log.Write("Delete AutoUpdateUPD.exe", typeof(Program), "Main", Log.LogType.DEBUG);
                    }
                }
                catch
                {
                    MessageBox.Show("Error deleting AutoUpdateUPD.exe, " + Application.ExecutablePath);
                }

                // Resolve update data, server address, program id
                string serverAddress = "";
                string productName = "";    // sent by main application that request update
                int productID = 0;          // sent by autoupdate program, self update
                Product product = null;
                bool result;

                // command line arguments, parse
                if (args.Length > 0)
                {
                    string[] commandAndValue;
                    foreach (string arg in args)
                    {
                        commandAndValue = arg.Split(new char[] { '=' });
                        if (commandAndValue.Length > 1)
                        {
                            if (commandAndValue[0] == "server")
                            {
                                serverAddress = commandAndValue[1];
                            }
                            else if (commandAndValue[0] == "productid")
                            {
                                // ProductID je sad productName, jer master app ima samo productName
                                // Obrisati kasnije
                                productName = commandAndValue[1];
                            }
                            else if (commandAndValue[0] == "productname")
                            {
                                productName = commandAndValue[1];
                            }
                            else if (commandAndValue[0] == "pid")
                            {
                                int.TryParse(commandAndValue[1], out productID);
//.........这里部分代码省略.........
开发者ID:dmarijanovic,项目名称:auto-update,代码行数:101,代码来源:Program.cs


注:本文中的Log.Show方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。