From 9525963721e43157f1b57d088743a6840dfed337 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=93=D0=B5=D0=BE=D1=80=D0=B3=D0=B8=D0=B9=20=D0=A6=D1=8B?= =?UTF-8?q?=D1=80=D0=BA=D0=BE=D0=B2?= Date: Fri, 9 Feb 2018 18:18:20 +0300 Subject: [PATCH] =?UTF-8?q?=D0=A0=D0=B5=D0=B0=D0=BB=D0=B8=D0=B7=D0=BE?= =?UTF-8?q?=D0=B2=D0=B0=D0=BD=20=D0=BF=D0=BE=D0=BC=D0=BE=D1=89=D0=BD=D0=B8?= =?UTF-8?q?=D0=BA=20=D0=BF=D0=BE=20=D1=81=D0=BE=D1=81=D1=82=D0=B0=D0=B2?= =?UTF-8?q?=D0=BB=D0=B5=D0=BD=D0=B8=D1=8E=20=D1=84=D0=BE=D1=80=D0=BC=20?= =?UTF-8?q?=D1=8D=D0=BA=D0=B7=D0=B0=D0=BC=D0=B5=D0=BD=D0=B0=D1=86=D0=B8?= =?UTF-8?q?=D0=BE=D0=BD=D0=BD=D1=8B=D1=85=20=D0=B1=D0=B8=D0=BB=D0=B5=D1=82?= =?UTF-8?q?=D0=BE=D0=B2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lecturerHelper.sln | 22 ++ lecturerHelper/App.config | 6 + lecturerHelper/Form_main.Designer.cs | 192 +++++++++++++++ lecturerHelper/Form_main.cs | 219 ++++++++++++++++++ lecturerHelper/Form_main.resx | 120 ++++++++++ lecturerHelper/Program.cs | 22 ++ lecturerHelper/Properties/AssemblyInfo.cs | 36 +++ .../Properties/Resources.Designer.cs | 71 ++++++ lecturerHelper/Properties/Resources.resx | 117 ++++++++++ .../Properties/Settings.Designer.cs | 30 +++ lecturerHelper/Properties/Settings.settings | 7 + lecturerHelper/lecturerHelper.csproj | 113 +++++++++ lecturerHelper/packages.config | 4 + 13 files changed, 959 insertions(+) create mode 100644 lecturerHelper.sln create mode 100644 lecturerHelper/App.config create mode 100644 lecturerHelper/Form_main.Designer.cs create mode 100644 lecturerHelper/Form_main.cs create mode 100644 lecturerHelper/Form_main.resx create mode 100644 lecturerHelper/Program.cs create mode 100644 lecturerHelper/Properties/AssemblyInfo.cs create mode 100644 lecturerHelper/Properties/Resources.Designer.cs create mode 100644 lecturerHelper/Properties/Resources.resx create mode 100644 lecturerHelper/Properties/Settings.Designer.cs create mode 100644 lecturerHelper/Properties/Settings.settings create mode 100644 lecturerHelper/lecturerHelper.csproj create mode 100644 lecturerHelper/packages.config diff --git a/lecturerHelper.sln b/lecturerHelper.sln new file mode 100644 index 0000000..6ab0c3b --- /dev/null +++ b/lecturerHelper.sln @@ -0,0 +1,22 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 14 +VisualStudioVersion = 14.0.25420.1 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "lecturerHelper", "lecturerHelper\lecturerHelper.csproj", "{CC26AA3F-694A-43FC-A8AE-26E5B11E097B}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {CC26AA3F-694A-43FC-A8AE-26E5B11E097B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {CC26AA3F-694A-43FC-A8AE-26E5B11E097B}.Debug|Any CPU.Build.0 = Debug|Any CPU + {CC26AA3F-694A-43FC-A8AE-26E5B11E097B}.Release|Any CPU.ActiveCfg = Release|Any CPU + {CC26AA3F-694A-43FC-A8AE-26E5B11E097B}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/lecturerHelper/App.config b/lecturerHelper/App.config new file mode 100644 index 0000000..8e15646 --- /dev/null +++ b/lecturerHelper/App.config @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/lecturerHelper/Form_main.Designer.cs b/lecturerHelper/Form_main.Designer.cs new file mode 100644 index 0000000..ee343ee --- /dev/null +++ b/lecturerHelper/Form_main.Designer.cs @@ -0,0 +1,192 @@ +namespace lecturerHelper +{ + partial class Form_main + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.xtraTabControl = new DevExpress.XtraTab.XtraTabControl(); + this.xtraTabPage1 = new DevExpress.XtraTab.XtraTabPage(); + this.simpleButton1 = new DevExpress.XtraEditors.SimpleButton(); + this.gridControl1 = new DevExpress.XtraGrid.GridControl(); + this.gridView1 = new DevExpress.XtraGrid.Views.Grid.GridView(); + this.simpleButton2 = new DevExpress.XtraEditors.SimpleButton(); + this.labelControl1 = new DevExpress.XtraEditors.LabelControl(); + this.textEdit1 = new DevExpress.XtraEditors.TextEdit(); + this.labelControl2 = new DevExpress.XtraEditors.LabelControl(); + this.spinEdit1 = new DevExpress.XtraEditors.SpinEdit(); + ((System.ComponentModel.ISupportInitialize)(this.xtraTabControl)).BeginInit(); + this.xtraTabControl.SuspendLayout(); + this.xtraTabPage1.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.gridControl1)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.gridView1)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.textEdit1.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.spinEdit1.Properties)).BeginInit(); + this.SuspendLayout(); + // + // xtraTabControl + // + this.xtraTabControl.Dock = System.Windows.Forms.DockStyle.Fill; + this.xtraTabControl.Location = new System.Drawing.Point(0, 0); + this.xtraTabControl.Name = "xtraTabControl"; + this.xtraTabControl.SelectedTabPage = this.xtraTabPage1; + this.xtraTabControl.Size = new System.Drawing.Size(879, 400); + this.xtraTabControl.TabIndex = 0; + this.xtraTabControl.TabPages.AddRange(new DevExpress.XtraTab.XtraTabPage[] { + this.xtraTabPage1}); + // + // xtraTabPage1 + // + this.xtraTabPage1.Controls.Add(this.spinEdit1); + this.xtraTabPage1.Controls.Add(this.labelControl2); + this.xtraTabPage1.Controls.Add(this.textEdit1); + this.xtraTabPage1.Controls.Add(this.labelControl1); + this.xtraTabPage1.Controls.Add(this.simpleButton2); + this.xtraTabPage1.Controls.Add(this.simpleButton1); + this.xtraTabPage1.Controls.Add(this.gridControl1); + this.xtraTabPage1.Name = "xtraTabPage1"; + this.xtraTabPage1.Size = new System.Drawing.Size(873, 372); + this.xtraTabPage1.Text = "Бланки билетов"; + // + // simpleButton1 + // + this.simpleButton1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.simpleButton1.Location = new System.Drawing.Point(686, 342); + this.simpleButton1.Name = "simpleButton1"; + this.simpleButton1.Size = new System.Drawing.Size(180, 23); + this.simpleButton1.TabIndex = 1; + this.simpleButton1.Text = "Сформировать бланки билетов"; + this.simpleButton1.Click += new System.EventHandler(this.simpleButton1_Click); + // + // gridControl1 + // + this.gridControl1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + | System.Windows.Forms.AnchorStyles.Left) + | System.Windows.Forms.AnchorStyles.Right))); + this.gridControl1.Location = new System.Drawing.Point(11, 37); + this.gridControl1.MainView = this.gridView1; + this.gridControl1.Name = "gridControl1"; + this.gridControl1.Size = new System.Drawing.Size(855, 299); + this.gridControl1.TabIndex = 0; + this.gridControl1.UseEmbeddedNavigator = true; + this.gridControl1.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] { + this.gridView1}); + // + // gridView1 + // + this.gridView1.GridControl = this.gridControl1; + this.gridView1.Name = "gridView1"; + this.gridView1.NewItemRowText = "ooo"; + this.gridView1.OptionsBehavior.CopyToClipboardWithColumnHeaders = false; + this.gridView1.OptionsSelection.MultiSelect = true; + this.gridView1.OptionsView.ColumnAutoWidth = false; + this.gridView1.OptionsView.ShowGroupPanel = false; + // + // simpleButton2 + // + this.simpleButton2.Location = new System.Drawing.Point(11, 8); + this.simpleButton2.Name = "simpleButton2"; + this.simpleButton2.Size = new System.Drawing.Size(125, 23); + this.simpleButton2.TabIndex = 2; + this.simpleButton2.Text = "Вставить из буфера"; + this.simpleButton2.Click += new System.EventHandler(this.simpleButton2_Click); + // + // labelControl1 + // + this.labelControl1.Location = new System.Drawing.Point(164, 13); + this.labelControl1.Name = "labelControl1"; + this.labelControl1.Size = new System.Drawing.Size(65, 13); + this.labelControl1.TabIndex = 3; + this.labelControl1.Text = "Дисциплина:"; + // + // textEdit1 + // + this.textEdit1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) + | System.Windows.Forms.AnchorStyles.Right))); + this.textEdit1.Location = new System.Drawing.Point(235, 10); + this.textEdit1.Name = "textEdit1"; + this.textEdit1.Size = new System.Drawing.Size(444, 20); + this.textEdit1.TabIndex = 4; + // + // labelControl2 + // + this.labelControl2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.labelControl2.Location = new System.Drawing.Point(686, 13); + this.labelControl2.Name = "labelControl2"; + this.labelControl2.Size = new System.Drawing.Size(90, 13); + this.labelControl2.TabIndex = 5; + this.labelControl2.Text = "Кегель вопросов:"; + // + // spinEdit1 + // + this.spinEdit1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.spinEdit1.EditValue = new decimal(new int[] { + 14, + 0, + 0, + 0}); + this.spinEdit1.Location = new System.Drawing.Point(782, 10); + this.spinEdit1.Name = "spinEdit1"; + this.spinEdit1.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); + this.spinEdit1.Size = new System.Drawing.Size(84, 20); + this.spinEdit1.TabIndex = 6; + // + // Form_main + // + this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.ClientSize = new System.Drawing.Size(879, 400); + this.Controls.Add(this.xtraTabControl); + this.Name = "Form_main"; + this.Text = "lecturerHelper"; + ((System.ComponentModel.ISupportInitialize)(this.xtraTabControl)).EndInit(); + this.xtraTabControl.ResumeLayout(false); + this.xtraTabPage1.ResumeLayout(false); + this.xtraTabPage1.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.gridControl1)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.gridView1)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.textEdit1.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.spinEdit1.Properties)).EndInit(); + this.ResumeLayout(false); + + } + + #endregion + + private DevExpress.XtraTab.XtraTabControl xtraTabControl; + private DevExpress.XtraTab.XtraTabPage xtraTabPage1; + private DevExpress.XtraGrid.GridControl gridControl1; + private DevExpress.XtraGrid.Views.Grid.GridView gridView1; + private DevExpress.XtraEditors.SimpleButton simpleButton1; + private DevExpress.XtraEditors.SimpleButton simpleButton2; + private DevExpress.XtraEditors.TextEdit textEdit1; + private DevExpress.XtraEditors.LabelControl labelControl1; + private DevExpress.XtraEditors.SpinEdit spinEdit1; + private DevExpress.XtraEditors.LabelControl labelControl2; + } +} + diff --git a/lecturerHelper/Form_main.cs b/lecturerHelper/Form_main.cs new file mode 100644 index 0000000..96dd25c --- /dev/null +++ b/lecturerHelper/Form_main.cs @@ -0,0 +1,219 @@ +using DevExpress.XtraEditors; +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; +using Xceed.Words.NET; + +namespace lecturerHelper +{ + public partial class Form_main : Form + { + public class QuestionPackData + { + [DisplayName("Номер билета")] + public int QuestionPackNumber { get; set; } + [DisplayName("Первый вопрос")] + public string FirstQuestion { get; set; } + [DisplayName("Второй вопрос")] + public string SecondQuestion { get; set; } + [DisplayName("Третий вопрос")] + public string ThirdQuestion { get; set; } + [DisplayName("Четвертый вопрос")] + public string FourthQuestion { get; set; } + [DisplayName("Пятый вопрос")] + public string FifthQuestion { get; set; } + + public QuestionPackData() + { + this.QuestionPackNumber = 0; + this.FirstQuestion = string.Empty; + this.SecondQuestion = string.Empty; + this.ThirdQuestion = string.Empty; + this.FourthQuestion = string.Empty; + this.FifthQuestion = string.Empty; + } + } + + string ClipboardData + { + get + { + IDataObject iData = Clipboard.GetDataObject(); + if (iData == null) return ""; + + if (iData.GetDataPresent(DataFormats.Text)) + return (string)iData.GetData(DataFormats.Text); + return ""; + } + set { Clipboard.SetDataObject(value); } + } + + public Form_main() + { + InitializeComponent(); + + BindingList data = new BindingList(); + data.AllowNew = true; + data.AllowRemove = true; + data.AllowEdit = true; + + this.gridControl1.DataSource = data; + this.gridControl1.RefreshDataSource(); + + for (int i = 0; i < this.gridView1.Columns.Count; i++) + { + this.gridView1.Columns[i].BestFit(); + } + } + + private void simpleButton1_Click(object sender, EventArgs e) + { + if (this.textEdit1.Text.Trim() == string.Empty) + { + + XtraMessageBox.Show("Введите название дисциплины", + "Ошибка", + MessageBoxButtons.OK, + MessageBoxIcon.Error); + return; + + } + + string partName = this.textEdit1.Text;// "Разработка САПР"; + int number = 1; + + DocX out_doc = DocX.Create("exam_output.docx", DocumentTypes.Document); + out_doc.MarginTop = 40; + out_doc.MarginBottom = 40; + out_doc.MarginLeft = 40; + out_doc.MarginRight = 40; + + if (this.gridControl1.DataSource is BindingList) + { + BindingList ds = (BindingList)this.gridControl1.DataSource; + + int nPageCount = 0; + for (int i = 0; i < ds.Count; i++) + { + nPageCount++; + Table nTab = out_doc.AddTable(2, 3); + nTab.SetWidths(new float[] { 150f, 300f, 90f }); + //nTab.AutoFit = AutoFit.Contents; + nTab.Rows[0].Cells[0].Paragraphs[0].Append("Федеральное государственное бюджетное образовательное учреждение высшего образования\n«Московский авиационный институт (национальный исследовательский университет)»").FontSize(10).Font("Times New Roman").Alignment = Alignment.center; + + nTab.Rows[0].Cells[1].Paragraphs[0].Append("Кафедра «316»").Font("Times New Roman").FontSize(12).Alignment = Alignment.center; + nTab.Rows[0].Cells[1].InsertParagraph("").Font("Times New Roman").FontSize(3).Alignment = Alignment.center; + nTab.Rows[0].Cells[1].InsertParagraph("Э К З А М Е Н А Ц И О Н Ы Й Б И Л Е Т").Font("Times New Roman").FontSize(12).Bold().Alignment = Alignment.center; + nTab.Rows[0].Cells[1].InsertParagraph("").Font("Times New Roman").FontSize(5).Alignment = Alignment.center; + nTab.Rows[0].Cells[1].InsertParagraph("№ ").Font("Times New Roman").FontSize(12).Bold().Alignment = Alignment.center; + nTab.Rows[0].Cells[1].Paragraphs[4].Append("__" + number + "__").Font("Times New Roman").FontSize(12).Bold().UnderlineStyle(UnderlineStyle.singleLine); + nTab.Rows[0].Cells[1].InsertParagraph("").Font("Times New Roman").FontSize(5).Alignment = Alignment.center; + nTab.Rows[0].Cells[1].InsertParagraph("По дисциплине «" + partName + "»").Font("Times New Roman").FontSize(12).Alignment = Alignment.center; + nTab.Rows[0].Cells[1].VerticalAlignment = VerticalAlignment.Center; + + nTab.Rows[0].Cells[2].Paragraphs[0].Append("«Утверждаю»").Font("Times New Roman").FontSize(12).Alignment = Alignment.center; + nTab.Rows[0].Cells[2].InsertParagraph("Зав. Кафедрой").Font("Times New Roman").FontSize(12).Italic().Alignment = Alignment.center; + nTab.Rows[0].Cells[2].InsertParagraph("").Font("Times New Roman").FontSize(12).Alignment = Alignment.center; + nTab.Rows[0].Cells[2].InsertParagraph("").Font("Times New Roman").FontSize(12).Alignment = Alignment.center; + nTab.Rows[0].Cells[2].InsertParagraph("________________").Font("Times New Roman").FontSize(12).Alignment = Alignment.center; + nTab.Rows[0].Cells[2].InsertParagraph("Хорошко Л.Л.").Font("Times New Roman").FontSize(12).Alignment = Alignment.center; + nTab.Rows[0].Cells[2].InsertParagraph("«__» _____ 20__ г.").Font("Times New Roman").FontSize(12).Alignment = Alignment.center; + nTab.Rows[0].Cells[2].VerticalAlignment = VerticalAlignment.Center; + + + nTab.Rows[1].MergeCells(0, 2); + nTab.Rows[1].Cells[0].InsertParagraph("").Font("Times New Roman").FontSize(12); + if (ds[i].FirstQuestion != string.Empty) + { + nTab.Rows[1].Cells[0].InsertParagraph(" 1. " + ds[i].FirstQuestion).Font("Times New Roman").FontSize((int)this.spinEdit1.Value); + } + if (ds[i].SecondQuestion != string.Empty) + { + nTab.Rows[1].Cells[0].InsertParagraph(" 2. " + ds[i].SecondQuestion).Font("Times New Roman").FontSize((int)this.spinEdit1.Value); + } + if (ds[i].ThirdQuestion != string.Empty) + { + nTab.Rows[1].Cells[0].InsertParagraph(" 3. " + ds[i].ThirdQuestion).Font("Times New Roman").FontSize((int)this.spinEdit1.Value); + } + if (ds[i].FourthQuestion != string.Empty) + { + nTab.Rows[1].Cells[0].InsertParagraph(" 4. " + ds[i].FourthQuestion).Font("Times New Roman").FontSize((int)this.spinEdit1.Value); + } + if (ds[i].FifthQuestion != string.Empty) + { + nTab.Rows[1].Cells[0].InsertParagraph(" 5. " + ds[i].FifthQuestion).Font("Times New Roman").FontSize((int)this.spinEdit1.Value); + } + + nTab.Rows[1].Height = 140; + + out_doc.InsertTable(nTab); + number++; + if (nPageCount > 2) + { + if (i < ds.Count - 1) + { + out_doc.InsertParagraph().InsertPageBreakAfterSelf(); + nPageCount = 0; + } + } + } + } + + out_doc.Save(); + + + DialogResult res = XtraMessageBox.Show("Открыть файл?", + "Вопрос", + MessageBoxButtons.YesNoCancel, + MessageBoxIcon.Question, + MessageBoxDefaultButton.Button2); + + if (res == DialogResult.Yes) + { + System.Diagnostics.Process.Start("exam_output.docx"); + } + } + + private void simpleButton2_Click(object sender, EventArgs e) + { + if (this.gridControl1.DataSource is BindingList) + { + BindingList ds = (BindingList)this.gridControl1.DataSource; + + string[] data = ClipboardData.Split('\n'); + if (data.Length < 1) return; + foreach (string row in data) + { + string[] rowData = row.Split(new char[] { '\r', '\x09' }); + QuestionPackData newData = new QuestionPackData(); + for (int i = 0; i < rowData.Length; i++) + { + if (i == 0) { int i_val = 0; int.TryParse(rowData[0], out i_val); newData.QuestionPackNumber = i_val; } + if (i == 1) { newData.FirstQuestion = rowData[1]; } + if (i == 2) { newData.SecondQuestion = rowData[2]; } + if (i == 3) { newData.ThirdQuestion = rowData[3]; } + if (i == 4) { newData.FourthQuestion = rowData[4]; } + if (i == 5) { newData.FifthQuestion = rowData[5]; } + } + if (rowData.Length > 1) + { + ds.Add(newData); + } + } + + this.gridControl1.RefreshDataSource(); + + for (int i = 0; i < this.gridView1.Columns.Count; i++) + { + this.gridView1.Columns[i].BestFit(); + } + } + } + } +} diff --git a/lecturerHelper/Form_main.resx b/lecturerHelper/Form_main.resx new file mode 100644 index 0000000..1af7de1 --- /dev/null +++ b/lecturerHelper/Form_main.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/lecturerHelper/Program.cs b/lecturerHelper/Program.cs new file mode 100644 index 0000000..1150ce1 --- /dev/null +++ b/lecturerHelper/Program.cs @@ -0,0 +1,22 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace lecturerHelper +{ + static class Program + { + /// + /// The main entry point for the application. + /// + [STAThread] + static void Main() + { + Application.EnableVisualStyles(); + Application.SetCompatibleTextRenderingDefault(false); + Application.Run(new Form_main()); + } + } +} diff --git a/lecturerHelper/Properties/AssemblyInfo.cs b/lecturerHelper/Properties/AssemblyInfo.cs new file mode 100644 index 0000000..85653e6 --- /dev/null +++ b/lecturerHelper/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +// General Information about an assembly is controlled through the following +// set of attributes. Change these attribute values to modify the information +// associated with an assembly. +[assembly: AssemblyTitle("lecturerHelper")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("lecturerHelper")] +[assembly: AssemblyCopyright("Copyright © 2018")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from +// COM, set the ComVisible attribute to true on that type. +[assembly: ComVisible(false)] + +// The following GUID is for the ID of the typelib if this project is exposed to COM +[assembly: Guid("cc26aa3f-694a-43fc-a8ae-26e5b11e097b")] + +// Version information for an assembly consists of the following four values: +// +// Major Version +// Minor Version +// Build Number +// Revision +// +// You can specify all the values or you can default the Build and Revision Numbers +// by using the '*' as shown below: +// [assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/lecturerHelper/Properties/Resources.Designer.cs b/lecturerHelper/Properties/Resources.Designer.cs new file mode 100644 index 0000000..618a590 --- /dev/null +++ b/lecturerHelper/Properties/Resources.Designer.cs @@ -0,0 +1,71 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Runtime Version:4.0.30319.42000 +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +namespace lecturerHelper.Properties +{ + + + /// + /// A strongly-typed resource class, for looking up localized strings, etc. + /// + // This class was auto-generated by the StronglyTypedResourceBuilder + // class via a tool like ResGen or Visual Studio. + // To add or remove a member, edit your .ResX file then rerun ResGen + // with the /str option, or rebuild your VS project. + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")] + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] + internal class Resources + { + + private static global::System.Resources.ResourceManager resourceMan; + + private static global::System.Globalization.CultureInfo resourceCulture; + + [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] + internal Resources() + { + } + + /// + /// Returns the cached ResourceManager instance used by this class. + /// + [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] + internal static global::System.Resources.ResourceManager ResourceManager + { + get + { + if ((resourceMan == null)) + { + global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("lecturerHelper.Properties.Resources", typeof(Resources).Assembly); + resourceMan = temp; + } + return resourceMan; + } + } + + /// + /// Overrides the current thread's CurrentUICulture property for all + /// resource lookups using this strongly typed resource class. + /// + [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] + internal static global::System.Globalization.CultureInfo Culture + { + get + { + return resourceCulture; + } + set + { + resourceCulture = value; + } + } + } +} diff --git a/lecturerHelper/Properties/Resources.resx b/lecturerHelper/Properties/Resources.resx new file mode 100644 index 0000000..af7dbeb --- /dev/null +++ b/lecturerHelper/Properties/Resources.resx @@ -0,0 +1,117 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/lecturerHelper/Properties/Settings.Designer.cs b/lecturerHelper/Properties/Settings.Designer.cs new file mode 100644 index 0000000..bf2f5d5 --- /dev/null +++ b/lecturerHelper/Properties/Settings.Designer.cs @@ -0,0 +1,30 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Runtime Version:4.0.30319.42000 +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +namespace lecturerHelper.Properties +{ + + + [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")] + internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase + { + + private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); + + public static Settings Default + { + get + { + return defaultInstance; + } + } + } +} diff --git a/lecturerHelper/Properties/Settings.settings b/lecturerHelper/Properties/Settings.settings new file mode 100644 index 0000000..3964565 --- /dev/null +++ b/lecturerHelper/Properties/Settings.settings @@ -0,0 +1,7 @@ + + + + + + + diff --git a/lecturerHelper/lecturerHelper.csproj b/lecturerHelper/lecturerHelper.csproj new file mode 100644 index 0000000..1bd9584 --- /dev/null +++ b/lecturerHelper/lecturerHelper.csproj @@ -0,0 +1,113 @@ + + + + + Debug + AnyCPU + {CC26AA3F-694A-43FC-A8AE-26E5B11E097B} + WinExe + Properties + lecturerHelper + lecturerHelper + v4.5 + 512 + + + AnyCPU + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + AnyCPU + none + true + bin\Release\ + TRACE + prompt + 4 + false + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ..\packages\DocX.1.1.0\lib\Xceed.Words.NET.dll + True + + + + + Form + + + Form_main.cs + + + + + Form_main.cs + + + ResXFileCodeGenerator + Resources.Designer.cs + Designer + + + True + Resources.resx + + + + SettingsSingleFileGenerator + Settings.Designer.cs + + + True + Settings.settings + True + + + + + + + + \ No newline at end of file diff --git a/lecturerHelper/packages.config b/lecturerHelper/packages.config new file mode 100644 index 0000000..e933f37 --- /dev/null +++ b/lecturerHelper/packages.config @@ -0,0 +1,4 @@ + + + + \ No newline at end of file