Subversion Repositories DevTools

Rev

Rev 2088 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
2088 ghuddy 1
using System;
2
using System.Drawing;
3
using System.Collections;
4
using System.ComponentModel;
5
using System.Windows.Forms;
6
 
7
namespace EA_DocGen
8
{
9
	/// <summary>
10
	/// Summary description for AboutForm.
11
	/// </summary>
12
	public class AboutForm : System.Windows.Forms.Form
13
	{
14
      private System.Windows.Forms.Label label1;
2094 ghuddy 15
      private System.Windows.Forms.LinkLabel linkLabel1;
2088 ghuddy 16
		/// <summary>
17
		/// Required designer variable.
18
		/// </summary>
19
		private System.ComponentModel.Container components = null;
20
 
21
		public AboutForm()
22
		{
23
			//
24
			// Required for Windows Form Designer support
25
			//
26
			InitializeComponent();
27
 
2094 ghuddy 28
         this.linkLabel1.Links[0].LinkData = "http://bms/docRegister/docDetail.asp?docnum=TECHGP-00177";
29
 
2088 ghuddy 30
			//
31
			// TODO: Add any constructor code after InitializeComponent call
32
			//
33
		}
34
 
35
		/// <summary>
36
		/// Clean up any resources being used.
37
		/// </summary>
38
		protected override void Dispose( bool disposing )
39
		{
40
			if( disposing )
41
			{
42
				if(components != null)
43
				{
44
					components.Dispose();
45
				}
46
			}
47
			base.Dispose( disposing );
48
		}
49
 
50
		#region Windows Form Designer generated code
51
		/// <summary>
52
		/// Required method for Designer support - do not modify
53
		/// the contents of this method with the code editor.
54
		/// </summary>
55
		private void InitializeComponent()
56
		{
57
         this.label1 = new System.Windows.Forms.Label();
2094 ghuddy 58
         this.linkLabel1 = new System.Windows.Forms.LinkLabel();
2088 ghuddy 59
         this.SuspendLayout();
60
         // 
61
         // label1
62
         // 
63
         this.label1.Location = new System.Drawing.Point(24, 8);
64
         this.label1.Name = "label1";
2094 ghuddy 65
         this.label1.Size = new System.Drawing.Size(320, 56);
2088 ghuddy 66
         this.label1.TabIndex = 0;
2094 ghuddy 67
         this.label1.Text = "ERG Enterprise Architect Document Generation Addin.";
2088 ghuddy 68
         // 
2094 ghuddy 69
         // linkLabel1
2088 ghuddy 70
         // 
2094 ghuddy 71
         this.linkLabel1.Location = new System.Drawing.Point(16, 96);
72
         this.linkLabel1.Name = "linkLabel1";
73
         this.linkLabel1.Size = new System.Drawing.Size(328, 16);
74
         this.linkLabel1.TabIndex = 3;
75
         this.linkLabel1.TabStop = true;
76
         this.linkLabel1.Text = "see TECHGP-00177 EA_DocGen User Manaual";
77
         this.linkLabel1.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabel1_LinkClicked);
2088 ghuddy 78
         // 
2094 ghuddy 79
         // AboutForm
2088 ghuddy 80
         // 
81
         this.AutoScaleBaseSize = new System.Drawing.Size(6, 15);
2094 ghuddy 82
         this.ClientSize = new System.Drawing.Size(360, 144);
83
         this.Controls.Add(this.linkLabel1);
2088 ghuddy 84
         this.Controls.Add(this.label1);
2094 ghuddy 85
         this.Name = "AboutForm";
2088 ghuddy 86
         this.Text = "About";
87
         this.ResumeLayout(false);
88
 
89
      }
90
		#endregion
91
 
2094 ghuddy 92
      private void linkLabel1_LinkClicked(object sender, System.Windows.Forms.LinkLabelLinkClickedEventArgs e)
93
      {
94
         // Determine which link was clicked within the LinkLabel.
95
         this.linkLabel1.Links[linkLabel1.Links.IndexOf(e.Link)].Visited = true;
2088 ghuddy 96
 
2094 ghuddy 97
         // Display the appropriate link based on the value of the 
98
         // LinkData property of the Link object.
99
         string target = e.Link.LinkData as string;
100
 
101
         // If the value looks like a URL, navigate to it.
102
         // Otherwise, display it in a message box.
103
         if(null != target && target.StartsWith("http"))
104
         {
105
            System.Diagnostics.Process.Start(target);
106
         }
107
         else
108
         {    
109
            MessageBox.Show("Item clicked: " + target);
110
         }
111
 
112
      }
113
 
114
 
115
 
116
 
2088 ghuddy 117
	}
118
}