diff --git a/Form1.Designer.cs b/Form1.Designer.cs index e43a977..41f1503 100644 --- a/Form1.Designer.cs +++ b/Form1.Designer.cs @@ -36,6 +36,7 @@ this.lbReqCnt = new System.Windows.Forms.Label(); this.lbRespCnt = new System.Windows.Forms.Label(); this.lbStatus = new System.Windows.Forms.Label(); + this.btOpen = new System.Windows.Forms.Button(); this.SuspendLayout(); // // Process @@ -91,11 +92,22 @@ this.lbStatus.TabIndex = 4; this.lbStatus.Text = "μƒνƒœ : λŒ€κΈ°"; // + // btOpen + // + this.btOpen.Location = new System.Drawing.Point(280, 49); + this.btOpen.Name = "btOpen"; + this.btOpen.Size = new System.Drawing.Size(75, 23); + this.btOpen.TabIndex = 5; + this.btOpen.Text = "Open"; + this.btOpen.UseVisualStyleBackColor = true; + this.btOpen.Click += new System.EventHandler(this.btOpen_Click); + // // Form1 // this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.ClientSize = new System.Drawing.Size(367, 212); + this.Controls.Add(this.btOpen); this.Controls.Add(this.lbStatus); this.Controls.Add(this.lbRespCnt); this.Controls.Add(this.lbReqCnt); @@ -118,6 +130,7 @@ private System.Windows.Forms.Label lbReqCnt; private System.Windows.Forms.Label lbRespCnt; private System.Windows.Forms.Label lbStatus; + private System.Windows.Forms.Button btOpen; } } diff --git a/Form1.cs b/Form1.cs index 9271a5b..8fbf702 100644 --- a/Form1.cs +++ b/Form1.cs @@ -19,7 +19,6 @@ namespace WebChecker int m_iReqCnt = 0; int m_iRespCnt = 0; - string m_strStatus = ""; DateTime m_LastCheckT; @@ -143,5 +142,22 @@ namespace WebChecker this.Show(); this.WindowState = FormWindowState.Normal; } + + private void btOpen_Click(object sender, EventArgs e) + { + try + { + System.Diagnostics.Process.Start(tbURL.Text); + } + catch(System.ComponentModel.Win32Exception noBrowser) + { + if(noBrowser.ErrorCode == -2147467259) + MessageBox.Show(noBrowser.Message); + } + catch(System.Exception other) + { + MessageBox.Show(other.Message); + } + } } } diff --git a/internet-url-31211.ico b/internet-url-31211.ico new file mode 100644 index 0000000..c414fe5 Binary files /dev/null and b/internet-url-31211.ico differ