Skip to content

Commit 2d71097

Browse files
committed
Finish?!
1 parent 2c913e1 commit 2d71097

14 files changed

+1574
-25
lines changed

About.Designer.cs

+100
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

About.cs

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
using System;
2+
using System.Drawing;
3+
using System.Windows.Forms;
4+
5+
namespace RDP_Portal {
6+
public partial class About : Form {
7+
public About() {
8+
InitializeComponent();
9+
}
10+
11+
private void About_Load(object sender, EventArgs e) {
12+
13+
Location = new Point(Owner.Location.X + Owner.Width / 2 - ClientSize.Width / 2,
14+
Owner.Location.Y + Owner.Height / 2 - ClientSize.Height / 2);
15+
16+
// https://stackoverflow.com/questions/909555/how-can-i-get-the-assembly-file-version
17+
System.Reflection.Assembly assembly = System.Reflection.Assembly.GetExecutingAssembly();
18+
System.Diagnostics.FileVersionInfo fvi = System.Diagnostics.FileVersionInfo.GetVersionInfo(assembly.Location);
19+
string version = fvi.FileVersion;
20+
21+
labelName.Text = "RDP Portal v" + version;
22+
}
23+
24+
private void buttonOK_Click(object sender, EventArgs e) {
25+
this.Close();
26+
}
27+
28+
private void linkLabel1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) {
29+
System.Diagnostics.Process.Start(((LinkLabel)sender).Text);
30+
}
31+
}
32+
}

0 commit comments

Comments
 (0)