From 859f6bc5e067d415d843735fdac149839291ec2b Mon Sep 17 00:00:00 2001 From: Daniel Romischer Date: Tue, 30 Aug 2016 16:34:29 -0400 Subject: [PATCH] checking in latest --- .../AzureContinuousDeployment.11.xaml | 686 ++++++++++++++++++ .../DefaultTemplate.11.1.xaml | 543 ++++++++++++++ .../LabDefaultTemplate.11.xaml | 203 ++++++ BuildProcessTemplates/UpgradeTemplate.xaml | 76 ++ QuickFTP/QuickFTP.v12.suo | Bin 178176 -> 159744 bytes .../gQuery/bin/Debug/gQuery.vshost.exe.config | 21 + .../bin/Debug/gQuery.vshost.exe.manifest | 11 + .../Advantage Final/Advantage Final.csproj | 6 +- Report Runner/Advantage Final/Form1.cs | 419 +++++------ .../Advantage Final/Options.Designer.cs | 135 ++-- Report Runner/Advantage Final/Options.cs | 87 ++- Report Runner/Advantage Final/Options.resx | 6 + .../Properties/Resources.Designer.cs | 6 +- .../Properties/Settings.Designer.cs | 6 +- Report Runner/Report Runner.sln | 14 +- Report Runner/Setup2/Setup2.vdproj | 53 +- 16 files changed, 1931 insertions(+), 341 deletions(-) create mode 100644 BuildProcessTemplates/AzureContinuousDeployment.11.xaml create mode 100644 BuildProcessTemplates/DefaultTemplate.11.1.xaml create mode 100644 BuildProcessTemplates/LabDefaultTemplate.11.xaml create mode 100644 BuildProcessTemplates/UpgradeTemplate.xaml create mode 100644 QuickFTP/gQuery/bin/Debug/gQuery.vshost.exe.config create mode 100644 QuickFTP/gQuery/bin/Debug/gQuery.vshost.exe.manifest diff --git a/BuildProcessTemplates/AzureContinuousDeployment.11.xaml b/BuildProcessTemplates/AzureContinuousDeployment.11.xaml new file mode 100644 index 0000000..1a08b91 --- /dev/null +++ b/BuildProcessTemplates/AzureContinuousDeployment.11.xaml @@ -0,0 +1,686 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + [New Microsoft.TeamFoundation.Build.Workflow.Activities.PlatformConfigurationList()] + [False] + [New Microsoft.TeamFoundation.Build.Workflow.Activities.TestSpecList(New Microsoft.TeamFoundation.Build.Workflow.Activities.AgileTestPlatformSpec("**\*test*.dll") With { .FailBuildOnFailure = True } )] + ["$(BuildDefinitionName)_$(Date:yyyyMMdd)$(Rev:.r)"] + [True] + [True] + [Microsoft.TeamFoundation.Build.Workflow.Activities.CleanWorkspaceOption.All] + + + + [Microsoft.TeamFoundation.Build.Workflow.Activities.CodeAnalysisOption.AsConfigured] + [True] + [Microsoft.TeamFoundation.Build.Workflow.Activities.ToolPlatform.Auto] + [True] + [New Microsoft.TeamFoundation.Build.Workflow.Activities.SourceAndSymbolServerSettings(True, Nothing)] + [True] + + + + [New Microsoft.TeamFoundation.Build.Workflow.Activities.AgentSettings() With {.MaxWaitTime = New System.TimeSpan(4, 0, 0), .MaxExecutionTime = New System.TimeSpan(0, 0, 0), .TagComparison = Microsoft.TeamFoundation.Build.Workflow.Activities.TagComparison.MatchExactly }] + [Microsoft.TeamFoundation.Build.Workflow.BuildVerbosity.Normal] + [True] + [True] + + + + + + + + + + + + + + + + + + + All + Assembly references and imported namespaces serialized as XML namespaces + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/BuildProcessTemplates/DefaultTemplate.11.1.xaml b/BuildProcessTemplates/DefaultTemplate.11.1.xaml new file mode 100644 index 0000000..063c42f --- /dev/null +++ b/BuildProcessTemplates/DefaultTemplate.11.1.xaml @@ -0,0 +1,543 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + [New Microsoft.TeamFoundation.Build.Workflow.Activities.BuildSettings()] + [False] + [New Microsoft.TeamFoundation.Build.Workflow.Activities.TestSpecList(New Microsoft.TeamFoundation.Build.Workflow.Activities.AgileTestPlatformSpec("**\*test*.dll"))] + ["$(BuildDefinitionName)_$(Date:yyyyMMdd)$(Rev:.r)"] + [False] + [True] + [True] + [Microsoft.TeamFoundation.Build.Workflow.Activities.CleanWorkspaceOption.All] + + + + [Microsoft.TeamFoundation.Build.Workflow.Activities.CodeAnalysisOption.AsConfigured] + [True] + [Microsoft.TeamFoundation.Build.Workflow.Activities.ToolPlatform.Auto] + [True] + [New Microsoft.TeamFoundation.Build.Workflow.Activities.SourceAndSymbolServerSettings(True, Nothing)] + [True] + + + + [New Microsoft.TeamFoundation.Build.Workflow.Activities.AgentSettings() With {.MaxWaitTime = New System.TimeSpan(4, 0, 0), .MaxExecutionTime = New System.TimeSpan(0, 0, 0), .TagComparison = Microsoft.TeamFoundation.Build.Workflow.Activities.TagComparison.MatchExactly }] + [Microsoft.TeamFoundation.Build.Workflow.BuildVerbosity.Normal] + + + + + + + All + 11.0 + Assembly references and imported namespaces serialized as XML namespaces + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/BuildProcessTemplates/LabDefaultTemplate.11.xaml b/BuildProcessTemplates/LabDefaultTemplate.11.xaml new file mode 100644 index 0000000..d5bca70 --- /dev/null +++ b/BuildProcessTemplates/LabDefaultTemplate.11.xaml @@ -0,0 +1,203 @@ + + + + + + + + + + + + + + + 11.0 + + + + + + 920,3702 + Assembly references and imported namespaces serialized as XML namespaces + + + + + + + + + + + + + + + + + + + + + + + [LabWorkflowParameters.BuildDetails.BuildUri] + + + [ChildBuildDetail.Uri] + + + + + + + + + + + + [BuildLocation] + + + [If(LabWorkflowParameters.BuildDetails.Configuration Is Nothing, BuildLocation, If(LabWorkflowParameters.BuildDetails.Configuration.IsEmpty Or (SelectedBuildDetail.Information.GetNodesByType(Microsoft.TeamFoundation.Build.Common.InformationTypes.ConfigurationSummary, True)).Count = 1, BuildLocation, If(LabWorkflowParameters.BuildDetails.Configuration.IsPlatformEmptyOrAnyCpu, BuildLocation + "\" + LabWorkflowParameters.BuildDetails.Configuration.Configuration, BuildLocation + "\" + LabWorkflowParameters.BuildDetails.Configuration.Platform + "\" + LabWorkflowParameters.BuildDetails.Configuration.Configuration)))] + + + + + + + + + + + + [LabEnvironmentUri] + + + [LabWorkflowParameters.EnvironmentDetails.LabEnvironmentUri.ToString()] + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + [PostDeploymentSnapshotName] + + + [If(LabWorkflowParameters.BuildDetails.IsTeamSystemBuild = True,String.Format("{0}_{1}_{2}", LabWorkflowParameters.DeploymentDetails.PostDeploymentSnapshotName, BuildNumber,BuildDetail.BuildNumber),String.Format("{0}_{1}", LabWorkflowParameters.DeploymentDetails.PostDeploymentSnapshotName, BuildDetail.BuildNumber))] + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + [BuildStatus] + + + [Microsoft.TeamFoundation.Build.Client.BuildStatus.PartiallySucceeded] + + + + + + + [BuildStatus] + + + [Microsoft.TeamFoundation.Build.Client.BuildStatus.Failed] + + + + + + + + + + + + \ No newline at end of file diff --git a/BuildProcessTemplates/UpgradeTemplate.xaml b/BuildProcessTemplates/UpgradeTemplate.xaml new file mode 100644 index 0000000..ea229be --- /dev/null +++ b/BuildProcessTemplates/UpgradeTemplate.xaml @@ -0,0 +1,76 @@ + + + + + + + + + + + + + + + + + + + + [New Microsoft.TeamFoundation.Build.Workflow.Activities.AgentSettings() With {.MaxWaitTime = New System.TimeSpan(4, 0, 0), .MaxExecutionTime = New System.TimeSpan(0, 0, 0), .TagComparison = Microsoft.TeamFoundation.Build.Workflow.Activities.TagComparison.MatchExactly }] + + + + [Microsoft.TeamFoundation.Build.Workflow.Activities.ToolPlatform.Auto] + [False] + [False] + + + + + + + + + + [Microsoft.TeamFoundation.VersionControl.Client.RecursionType.OneLevel] + [Microsoft.TeamFoundation.Build.Workflow.BuildVerbosity.Normal] + + + + All + Assembly references and imported namespaces serialized as XML namespaces + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/QuickFTP/QuickFTP.v12.suo b/QuickFTP/QuickFTP.v12.suo index 25aa5a0ebe64009d24c41cf86aee63c8ad98ffc2..9dc3b3c3805422291c9ff2fb19d0cdef9ebaaab2 100644 GIT binary patch delta 941 zcmZ{iT}TvB6oB_!XLfdVmUhk7^(UFt&7U-N)yiba(lAp{dn#gu3h7B`qY)*drXmoO zaOXVCOK4~eB1N_XZcibs^kkI%Jq1RfSx-UhLuhN~s)a8Od~@zO_x#;+ul6%t`{Eo4 z<rrr^OQTx8r?B z2`JW6$2qVB_d3L6m07BH7-H^+Ag_?icj6a;lNkY#_n)#BJl7eXl5b<8GH4}b8T3FQ z7FPOQ&_Is41aFg%Li|R`oZ*>-DnprseC!Ga_(J*r+s%X*+kJZeoXlrfxFe&L%$EVR zv|=n)3WOrsF*+VW1*%Gy93qWR^j~#MDs=3V!HJ|FFxl40`^9P|;6Tx!UZBE))#n=m z-J5XP7=`WM5o#s9GK`lpJi{q@dDMFKku|_w?lO z;ndIt))JYN>oCb9#9sb-qLFo+oemkPe#oj$rQ}7{sboho$Dy1vaR5 zOI137Pe5Fx3bOUPSz>yA0uxPiZ#2hPODH=%NG^J@w|Ax&2K>gr1Pq!cu(&n?qe6W2EsTjGf2zTF({zWF&T54rA#2~#@7I=Ga?nt9&e~%uhM2}n6EbOn_w&QU(atkAOHXW delta 1804 zcmbu9ZA?>F7=Z8l(w0&#P(Cc6&=o}K3c&&@AH#SDh-6G;8=KRB86QQy2F0}*?yJ|J z&P~M8!#D;Bi)`uGmMt4K_UD>O7PI&VR zLmX%*Aeo>!VK#5diMvIHaEg||K(o--#J8Db{-g2km4J+hqaY%;khBxU5nBY6tkH#CN_H7h zPCP|a5IYGmCYnNeWyG!`*(eTb)S1Q_O44GQA_J`qno^&3L@Y6_bB*3bdN+%~gN352z{1M(yR|xs$z{j& zxsc`mQoj%6A#xleP7=&$NHL0Y7Yvg_NVe6`DbJAc*{Wm4aG5!q^=vTK%G6lBeZQ6jdN!7^a(C&B1!%<#ywJfegTsy74QXTM@-)%kx)1~N5 zn_G!oN|V8BcEL5~HhbVS3z@^(Q#7NI-A%8P#SLVyneTTgdx2fT!jG3W0GL@QW3Mbq zWwku00}R9R{iDtd z_KHITrU!;~wj)QI@(e}Q5n|S!h-9TD4RRY9?GeY&SWjTA2X1D?+i5ZSt#AzZ@zcqg)S zuyfA{?BoBO0o%nhFs0?@4BA2rN%P z6zC-JqRL!13FSOE0r|Xo5>mLa17&XMqD~bib;?66g?rC~4cY?VP6A*+`3Mx`!6{IE z(|}w(53Rhl9nBZpQ3an5G`^o9+jj+OK0%`|8#O))>U=gtUjZWjH3zqHrww(1avOdR zd?67HT**Tl`zlk%7jrNrP;bW{in#F{n0SE$uX5Fa!9cJBX+OFSjOX?e~&Y|;`?d+Bd-r3V$JTxjR_ zUkB5t<$Va+4v8MVvmZC{oBf#Kv!gO=4T4gzm>fTT=ilAW9XN4sT}$4 + + + +
+ + + + + + C:\medidata\18\testtest + + + user + + + password + + + + \ No newline at end of file diff --git a/QuickFTP/gQuery/bin/Debug/gQuery.vshost.exe.manifest b/QuickFTP/gQuery/bin/Debug/gQuery.vshost.exe.manifest new file mode 100644 index 0000000..061c9ca --- /dev/null +++ b/QuickFTP/gQuery/bin/Debug/gQuery.vshost.exe.manifest @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/Report Runner/Advantage Final/Advantage Final.csproj b/Report Runner/Advantage Final/Advantage Final.csproj index 8d548a9..1ea8b01 100644 --- a/Report Runner/Advantage Final/Advantage Final.csproj +++ b/Report Runner/Advantage Final/Advantage Final.csproj @@ -8,7 +8,7 @@ {1F135F26-23F8-4EA6-B000-9D22FBE1B273} WinExe Properties - Report_Runner + Advantage_Final Report Runner v4.0 @@ -30,6 +30,10 @@ false true true + SAK + SAK + SAK + SAK x86 diff --git a/Report Runner/Advantage Final/Form1.cs b/Report Runner/Advantage Final/Form1.cs index 532e3bf..b5e4348 100644 --- a/Report Runner/Advantage Final/Form1.cs +++ b/Report Runner/Advantage Final/Form1.cs @@ -30,7 +30,6 @@ namespace Advantage_Final public string line; public string PracticeFolder; public string oldPath; - public Form1() @@ -69,33 +68,6 @@ namespace Advantage_Final } - - - - - - - - - - private void exitToolStripMenuItem1_Click(object sender, EventArgs e) - { - Application.Exit(); - } - - private void exitToolStripMenuItem_Click(object sender, EventArgs e) - { - - } - - private void setPathsToolStripMenuItem_Click(object sender, EventArgs e) - { - FilePaths frmFilePaths = new FilePaths(); - frmFilePaths.ShowDialog(); - - } - - private void InitializeDataComponents() { @@ -113,244 +85,237 @@ namespace Advantage_Final } + #region Click event handlers - private void button1_Click(object sender, EventArgs e) - { - for (int i = 0; i < mPracticeList.Items.Count; i++) + /// + /// Select All + /// + private void button1_Click(object sender, EventArgs e) + { + for (int i = 0; i < mPracticeList.Items.Count; i++) - mPracticeList.SetItemChecked(i, true); - } + mPracticeList.SetItemChecked(i, true); + } - private void button2_Click(object sender, EventArgs e) - { + /// + /// Copy Reports + /// + private void button2_Click(object sender, EventArgs e) + { - list.Clear(); + list.Clear(); - foreach (string item in mPracticeList.CheckedItems) - { - string value = item; - int i = item.IndexOf('{') + 1; - string d = Path.Combine(value.Substring(i) + "\\ureports"); - list.Add(d); + foreach (string item in mPracticeList.CheckedItems) + { + string value = item; + int i = item.IndexOf('{') + 1; + string d = Path.Combine(value.Substring(i) + "\\ureports"); + list.Add(d); - } + } - { + { - if ((string)Dicks.GetValue("ReportFolder") == null) - { - reportFileDialog1.InitialDirectory = @"C:\"; - } - else - { - reportFileDialog1.InitialDirectory = ((string)Dicks.GetValue("ReportFolder")); - } + if ((string)Dicks.GetValue("ReportFolder") == null) + { + reportFileDialog1.InitialDirectory = @"C:\"; + } + else + { + reportFileDialog1.InitialDirectory = ((string)Dicks.GetValue("ReportFolder")); + } - DialogResult result = reportFileDialog1.ShowDialog(); - Class1.ReportName = System.IO.Path.GetFileNameWithoutExtension(reportFileDialog1.FileName); - if (result == DialogResult.OK) - { - foreach (String file in reportFileDialog1.FileNames) - { - foreach (string item in list) - { - try - { + DialogResult result = reportFileDialog1.ShowDialog(); + Class1.ReportName = System.IO.Path.GetFileNameWithoutExtension(reportFileDialog1.FileName); + if (result == DialogResult.OK) + { + foreach (String file in reportFileDialog1.FileNames) + { + foreach (string item in list) + { + try + { - string otherFile = Path.Combine(item, Path.GetFileName(file)); - File.Copy(file, otherFile, true); - } - catch (UnauthorizedAccessException ) - { - MessageBox.Show("Fix your fucking permissions"); - } + string otherFile = Path.Combine(item, Path.GetFileName(file)); + File.Copy(file, otherFile, true); + } + catch (UnauthorizedAccessException ) + { + MessageBox.Show("Fix your fucking permissions"); + } - catch (IOException) - { - MessageBox.Show("This shit doesn't exist" + item); - } + catch (IOException) + { + MessageBox.Show("This shit doesn't exist" + item); + } - catch (Exception) - { + catch (Exception) + { - } - } + } + } - } + } - } + } - } - } - + } + } - private void button3_Click(object sender, EventArgs e) - { + /// + /// Run Report + /// + private void button3_Click(object sender, EventArgs e) + { - list.Clear(); + list.Clear(); - foreach (string item in mPracticeList.CheckedItems) - { - string value = item; - int i = item.IndexOf('{') + 1; - string d = Path.Combine(value.Substring(i) + "\\mwddf.add"); - list.Add(d); + foreach (string item in mPracticeList.CheckedItems) + { + string value = item; + int i = item.IndexOf('{') + 1; + string d = Path.Combine(value.Substring(i) + "\\mwddf.add"); + list.Add(d); - } + } - { + { - if ((string)Dicks.GetValue("ReportFolder") == null) - { - reportFileDialog1.InitialDirectory = @"C:\"; - } - else - { - reportFileDialog1.InitialDirectory = ((string)Dicks.GetValue("ReportFolder")); - } + if ((string)Dicks.GetValue("ReportFolder") == null) + { + reportFileDialog1.InitialDirectory = @"C:\"; + } + else + { + reportFileDialog1.InitialDirectory = ((string)Dicks.GetValue("ReportFolder")); + } - DialogResult result = reportFileDialog1.ShowDialog(); + DialogResult result = reportFileDialog1.ShowDialog(); - if (result == DialogResult.OK) - { + if (result == DialogResult.OK) + { - using (StreamReader sr = new StreamReader(reportFileDialog1.FileName)) - { + using (StreamReader sr = new StreamReader(reportFileDialog1.FileName)) + { - line = sr.ReadToEnd(); + line = sr.ReadToEnd(); - } + } - foreach (string item in list) - { + foreach (string item in list) + { - { + { - try - { + try + { - oldPath = item.Replace("\\mwddf.add", ""); - int i1 = oldPath.LastIndexOf('\\'); - string newPracticeName = oldPath.Substring(i1); - AdsConnection conn = new AdsConnection(); - conn.ConnectionString = "Data Source=" + item + + oldPath = item.Replace("\\mwddf.add", ""); + int i1 = oldPath.LastIndexOf('\\'); + string newPracticeName = oldPath.Substring(i1); + AdsConnection conn = new AdsConnection(); + conn.ConnectionString = "Data Source=" + item + ";User ID=user;Password=password;" + "ServerType=REMOTE|LOCAL;TrimTrailingSpaces=True"; - AdsDataAdapter da = new AdsDataAdapter(line, conn); - DataSet ds = new DataSet(); - da.SelectCommand.CommandTimeout = 0; - da.Fill(ds, "Dick"); - DataTable dt = ds.Tables[0]; - string filepath = (string)Dicks.GetValue("ReportOutput", ""); - da.Dispose(); + AdsDataAdapter da = new AdsDataAdapter(line, conn); + DataSet ds = new DataSet(); + da.SelectCommand.CommandTimeout = 0; + da.Fill(ds, "Dick"); + DataTable dt = ds.Tables[0]; + string filepath = (string)Dicks.GetValue("ReportOutput", ""); + da.Dispose(); - conn.Open(); - AdsDataReader reader; - AdsCommand PracticeName = conn.CreateCommand(); - PracticeName.CommandText = "SELECT [Practice Name] FROM [MWPRA]"; + conn.Open(); + AdsDataReader reader; + AdsCommand PracticeName = conn.CreateCommand(); + PracticeName.CommandText = "SELECT [Practice Name] FROM [MWPRA]"; - reader = PracticeName.ExecuteReader(); + reader = PracticeName.ExecuteReader(); - while (reader.Read()) - { + while (reader.Read()) + { - PracticeFolder = reader.GetString(0); + PracticeFolder = reader.GetString(0); - } - dt.Columns.Add("Practice", typeof(string)); - foreach (DataRow dr in dt.Rows) - { - dr["Practice"] = PracticeFolder; - } - conn.Close(); - AdsConnection.FlushConnectionPool(); + } + dt.Columns.Add("Practice", typeof(string)); + foreach (DataRow dr in dt.Rows) + { + dr["Practice"] = PracticeFolder; + } + conn.Close(); + AdsConnection.FlushConnectionPool(); - string ReportExportPath1 = (Path.Combine((string)Dicks.GetValue("ReportOutput", ""))); - //string ReportExportPath1 = (Path.Combine((string)Dicks.GetValue("ReportOutput", "") + newPracticeName)); - string ReportExportPath = ReportExportPath1.TrimEnd('\\'); - bool exists = System.IO.Directory.Exists(ReportExportPath); + string ReportExportPath1 = (Path.Combine((string)Dicks.GetValue("ReportOutput", ""))); + //string ReportExportPath1 = (Path.Combine((string)Dicks.GetValue("ReportOutput", "") + newPracticeName)); + string ReportExportPath = ReportExportPath1.TrimEnd('\\'); + bool exists = System.IO.Directory.Exists(ReportExportPath); - if (!exists) - System.IO.Directory.CreateDirectory(ReportExportPath); + if (!exists) + System.IO.Directory.CreateDirectory(ReportExportPath); - // String rFilePath = (ReportExportPath + "\\" + Path.GetFileNameWithoutExtension(reportFileDialog1.FileName) + ".xlsx"); - String rFilePath = (ReportExportPath + "\\" + "Test" + ".xlsx"); + // String rFilePath = (ReportExportPath + "\\" + Path.GetFileNameWithoutExtension(reportFileDialog1.FileName) + ".xlsx"); + String rFilePath = (ReportExportPath + "\\" + "Test" + ".xlsx"); - dt.ExportToExcel(rFilePath); - dt.Dispose(); - ds.Dispose(); - conn.Close(); + dt.ExportToExcel(rFilePath); + dt.Dispose(); + ds.Dispose(); + conn.Close(); - } - catch (Exception ex) - { + } + catch (Exception ex) + { - string LogPath = ((Path.Combine((string)Dicks.GetValue("ReportOutput", "") + "\\" + "log.txt"))); - bool fileExists = File.Exists(LogPath); - using (StreamWriter sw = File.AppendText(LogPath)) - { - sw.WriteLine(""); - sw.WriteLine(ex); - sw.WriteLine(""); - sw.WriteLine(oldPath); + string LogPath = ((Path.Combine((string)Dicks.GetValue("ReportOutput", "") + "\\" + "log.txt"))); + bool fileExists = File.Exists(LogPath); + using (StreamWriter sw = File.AppendText(LogPath)) + { + sw.WriteLine(""); + sw.WriteLine(ex); + sw.WriteLine(""); + sw.WriteLine(oldPath); - } + } - } - continue; + } + continue; - } + } - } + } - } + } - } - MessageBox.Show("All Done"); - } - - - - private void mPracticeList_SelectedIndexChanged(object sender, EventArgs e) - { - - } - - private void openFileDialog1_FileOk(object sender, CancelEventArgs e) - { - - } - - private void mPracticeList_SelectedIndexChanged_1(object sender, EventArgs e) - { - - } - - private void openFileDialog1_FileOk_1(object sender, CancelEventArgs e) - { - - } + } + MessageBox.Show("All Done"); + } + /// + /// Remove Selected + /// private void btnClear_Click(object sender, EventArgs e) { foreach (int i in mPracticeList.CheckedIndices) { - mPracticeList.SetItemCheckState(i,CheckState.Unchecked); + mPracticeList.SetItemCheckState(i,CheckState.Unchecked); } } + /// + /// Run Script + /// private void btnScript_Click(object sender, EventArgs e) { @@ -391,8 +356,8 @@ namespace Advantage_Final { string connString = "Data Source=" + item + - ";User ID=user;Password=password;" + - "ServerType=REMOTE|LOCAL;TrimTrailingSpaces=True"; + ";User ID=user;Password=password;" + + "ServerType=REMOTE|LOCAL;TrimTrailingSpaces=True"; AdsCommand justQuery = new AdsCommand(); justQuery.Connection = new AdsConnection(connString); @@ -413,6 +378,9 @@ namespace Advantage_Final } + /// + /// ClearforRM + /// private void button3_Click_1(object sender, EventArgs e) { string RMPath = ((string)RMRoot.GetValue("Root Data Path")); @@ -420,7 +388,7 @@ namespace Advantage_Final connection = new AdsConnection(); connection.ConnectionString = "Data Source=" + RMPath + "\\CMDBLIST.ADD" + ";User ID=user;Password=password" + - ";ServerType=REMOTE|LOCAL;TrimTrailingSpaces=True"; + ";ServerType=REMOTE|LOCAL;TrimTrailingSpaces=True"; AdsDataReader reader; AdsCommand cmd; cmd = connection.CreateCommand(); @@ -439,6 +407,9 @@ namespace Advantage_Final } + /// + /// UpdateRM + /// private void button4_Click(object sender, EventArgs e) { list.Clear(); @@ -478,8 +449,8 @@ namespace Advantage_Final { { string connString = "Data Source=" + item + - ";User ID=user;Password=password;" + - "ServerType=REMOTE|LOCAL;TrimTrailingSpaces=True"; + ";User ID=user;Password=password;" + + "ServerType=REMOTE|LOCAL;TrimTrailingSpaces=True"; AdsCommand justQuery = new AdsCommand(); justQuery.Connection = new AdsConnection(connString); @@ -514,18 +485,60 @@ namespace Advantage_Final } - private void optionsToolStripMenuItem_Click(object sender, EventArgs e) + #endregion + + #region ToolStrip Menu + + private void optionsToolStripMenuItem_Click(object sender, EventArgs e) { - + Options frmOptions = new Options(); + frmOptions.ShowDialog(); } + private void exitToolStripMenuItem1_Click(object sender, EventArgs e) + { + Application.Exit(); + } + private void exitToolStripMenuItem_Click(object sender, EventArgs e) + { + + } + private void setPathsToolStripMenuItem_Click(object sender, EventArgs e) + { + FilePaths frmFilePaths = new FilePaths(); + frmFilePaths.ShowDialog(); } + #endregion + #region JUNK + private void openFileDialog1_FileOk(object sender, CancelEventArgs e) + { + + } + + private void openFileDialog1_FileOk_1(object sender, CancelEventArgs e) + { + + } + + private void mPracticeList_SelectedIndexChanged(object sender, EventArgs e) + { + + } + + private void mPracticeList_SelectedIndexChanged_1(object sender, EventArgs e) + { + + } + + #endregion } +} + diff --git a/Report Runner/Advantage Final/Options.Designer.cs b/Report Runner/Advantage Final/Options.Designer.cs index e8802b6..2ff6b43 100644 --- a/Report Runner/Advantage Final/Options.Designer.cs +++ b/Report Runner/Advantage Final/Options.Designer.cs @@ -1,4 +1,4 @@ -namespace Report_Runner +namespace Advantage_Final { partial class Options { @@ -28,100 +28,75 @@ /// private void InitializeComponent() { - this.checkSeparate = new System.Windows.Forms.CheckBox(); - this.label1 = new System.Windows.Forms.Label(); - this.checkedListBox1 = new System.Windows.Forms.CheckedListBox(); + this.lblReportPath = new System.Windows.Forms.Label(); + this.btnExit = new System.Windows.Forms.Button(); + this.lblReportOutput = new System.Windows.Forms.Label(); + this.reportFolder = new System.Windows.Forms.FolderBrowserDialog(); + this.reportOutput = new System.Windows.Forms.FolderBrowserDialog(); this.checkBox1 = new System.Windows.Forms.CheckBox(); - this.label2 = new System.Windows.Forms.Label(); - this.label3 = new System.Windows.Forms.Label(); - this.checkedListBox2 = new System.Windows.Forms.CheckedListBox(); + this.checkBox2 = new System.Windows.Forms.CheckBox(); this.SuspendLayout(); // - // checkSeparate + // lblReportPath // - this.checkSeparate.AutoSize = true; - this.checkSeparate.Location = new System.Drawing.Point(18, 23); - this.checkSeparate.Name = "checkSeparate"; - this.checkSeparate.Size = new System.Drawing.Size(128, 17); - this.checkSeparate.TabIndex = 0; - this.checkSeparate.Text = "Separate Report Files"; - this.checkSeparate.UseVisualStyleBackColor = true; + this.lblReportPath.AutoSize = true; + this.lblReportPath.Location = new System.Drawing.Point(12, 38); + this.lblReportPath.Name = "lblReportPath"; + this.lblReportPath.Size = new System.Drawing.Size(64, 13); + this.lblReportPath.TabIndex = 0; + this.lblReportPath.Text = "Report Path"; // - // label1 + // btnExit // - this.label1.AutoSize = true; - this.label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label1.Location = new System.Drawing.Point(15, 64); - this.label1.Name = "label1"; - this.label1.Size = new System.Drawing.Size(97, 24); - this.label1.TabIndex = 2; - this.label1.Text = "File Name"; + this.btnExit.Location = new System.Drawing.Point(683, 383); + this.btnExit.Name = "btnExit"; + this.btnExit.Size = new System.Drawing.Size(114, 30); + this.btnExit.TabIndex = 1; + this.btnExit.Text = "Exit"; + this.btnExit.UseVisualStyleBackColor = true; + this.btnExit.Click += new System.EventHandler(this.btnExit_Click); // - // checkedListBox1 + // lblReportOutput // - this.checkedListBox1.FormattingEnabled = true; - this.checkedListBox1.Items.AddRange(new object[] { - "Practice Name", - "Report Name"}); - this.checkedListBox1.Location = new System.Drawing.Point(15, 91); - this.checkedListBox1.Name = "checkedListBox1"; - this.checkedListBox1.Size = new System.Drawing.Size(97, 34); - this.checkedListBox1.TabIndex = 3; + this.lblReportOutput.AutoSize = true; + this.lblReportOutput.Location = new System.Drawing.Point(12, 80); + this.lblReportOutput.Name = "lblReportOutput"; + this.lblReportOutput.Size = new System.Drawing.Size(74, 13); + this.lblReportOutput.TabIndex = 2; + this.lblReportOutput.Text = "Report Output"; // // checkBox1 // this.checkBox1.AutoSize = true; - this.checkBox1.Location = new System.Drawing.Point(166, 91); + this.checkBox1.Location = new System.Drawing.Point(384, 66); this.checkBox1.Name = "checkBox1"; - this.checkBox1.Size = new System.Drawing.Size(97, 17); - this.checkBox1.TabIndex = 4; - this.checkBox1.Text = "MonthDayYear"; + this.checkBox1.Size = new System.Drawing.Size(109, 17); + this.checkBox1.TabIndex = 3; + this.checkBox1.Text = "Separate Reports"; this.checkBox1.UseVisualStyleBackColor = true; // - // label2 + // checkBox2 // - this.label2.AutoSize = true; - this.label2.Location = new System.Drawing.Point(133, 105); - this.label2.Name = "label2"; - this.label2.Size = new System.Drawing.Size(13, 13); - this.label2.TabIndex = 5; - this.label2.Text = "+"; + this.checkBox2.AutoSize = true; + this.checkBox2.Location = new System.Drawing.Point(368, 146); + this.checkBox2.Name = "checkBox2"; + this.checkBox2.Size = new System.Drawing.Size(158, 17); + this.checkBox2.TabIndex = 4; + this.checkBox2.Text = "Add Mm-DD-YY to file name"; + this.checkBox2.UseVisualStyleBackColor = true; // - // label3 - // - this.label3.AutoSize = true; - this.label3.Location = new System.Drawing.Point(15, 139); - this.label3.Name = "label3"; - this.label3.Size = new System.Drawing.Size(67, 13); - this.label3.TabIndex = 6; - this.label3.Text = "Folder Name"; - // - // checkedListBox2 - // - this.checkedListBox2.FormattingEnabled = true; - this.checkedListBox2.Items.AddRange(new object[] { - "Use Report Folder", - "Practice Name", - "Report Name"}); - this.checkedListBox2.Location = new System.Drawing.Point(15, 155); - this.checkedListBox2.Name = "checkedListBox2"; - this.checkedListBox2.Size = new System.Drawing.Size(120, 49); - this.checkedListBox2.TabIndex = 7; - // - // Form2 + // Options // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(371, 261); - this.Controls.Add(this.checkedListBox2); - this.Controls.Add(this.label3); - this.Controls.Add(this.label2); + this.ClientSize = new System.Drawing.Size(846, 434); + this.Controls.Add(this.checkBox2); this.Controls.Add(this.checkBox1); - this.Controls.Add(this.checkedListBox1); - this.Controls.Add(this.label1); - this.Controls.Add(this.checkSeparate); - this.Name = "Form2"; - this.Text = "Options"; + this.Controls.Add(this.lblReportOutput); + this.Controls.Add(this.btnExit); + this.Controls.Add(this.lblReportPath); + this.Name = "Options"; + this.Text = "Form2"; this.ResumeLayout(false); this.PerformLayout(); @@ -129,12 +104,12 @@ #endregion - private System.Windows.Forms.CheckBox checkSeparate; - private System.Windows.Forms.Label label1; - private System.Windows.Forms.CheckedListBox checkedListBox1; + private System.Windows.Forms.Label lblReportPath; + private System.Windows.Forms.Button btnExit; + private System.Windows.Forms.Label lblReportOutput; + private System.Windows.Forms.FolderBrowserDialog reportFolder; + private System.Windows.Forms.FolderBrowserDialog reportOutput; private System.Windows.Forms.CheckBox checkBox1; - private System.Windows.Forms.Label label2; - private System.Windows.Forms.Label label3; - private System.Windows.Forms.CheckedListBox checkedListBox2; + private System.Windows.Forms.CheckBox checkBox2; } } \ No newline at end of file diff --git a/Report Runner/Advantage Final/Options.cs b/Report Runner/Advantage Final/Options.cs index 323f062..a43839f 100644 --- a/Report Runner/Advantage Final/Options.cs +++ b/Report Runner/Advantage Final/Options.cs @@ -1,4 +1,5 @@ -using System; +using Microsoft.Win32; +using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; @@ -6,14 +7,96 @@ using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; +using System.IO; -namespace Report_Runner +namespace Advantage_Final { public partial class Options : Form { public Options() { InitializeComponent(); + //textReportOutput.Text = (string)Dicks.GetValue("ReportOutput", ""); + //textBox1.Text = (string)Dicks.GetValue("ReportFolder", ""); + } + + public RegistryKey Dicks = Microsoft.Win32.Registry.CurrentUser.OpenSubKey("Software\\PanaceanTech\\ReportRunner", true); + + + private void Form1_Load(object sender, EventArgs e) + { + + + } + + + private void button1_Click(object sender, EventArgs e) + { + + // + // This event handler was created by double-clicking the window in the designer. + // It runs on the program's startup routine. + // + //DialogResult result = reportFolder.ShowDialog(); + //if (result == DialogResult.OK) + //{ + // Dicks.SetValue("ReportFolder", reportFolder.SelectedPath); + // textBox1.Text = (string)Dicks.GetValue("ReportFolder"); + + //} + } + + private void btnExit_Click(object sender, EventArgs e) + { + this.Hide(); + } + + private void textBox1_Leave(object sender, EventArgs e) + { + //if (System.IO.Directory.Exists(textBox1.Text)) + //{ + // Dicks.SetValue("ReportFolder", textBox1.Text.TrimEnd('\\')); + // textBox1.Text = (string)Dicks.GetValue("ReportFolder"); + //} + //else + //{ + // MessageBox.Show("Enter a valid path. Quit trying to break shit"); + // textBox1.Text = ""; + + //} + } + + private void btnOutPath_Click(object sender, EventArgs e) + { + //DialogResult result = reportOutput.ShowDialog(); + //if (result == DialogResult.OK) + //{ + // Dicks.SetValue("ReportOutput", reportOutput.SelectedPath); + // textReportOutput.Text = (string)Dicks.GetValue("ReportOutput"); + + //} + } + + private void textReportOutput_Leave(object sender, EventArgs e) + { + //if (System.IO.Directory.Exists(textReportOutput.Text)) + //{ + // Dicks.SetValue("ReportOutput", textReportOutput.Text.TrimEnd('\\')); + // textReportOutput.Text = (string)Dicks.GetValue("ReportOutput"); + //} + //else + //{ + // MessageBox.Show("Enter a valid path. Quit trying to break shit"); + // textBox1.Text = ""; + + //} + } + + private void textReportOutput_TextChanged(object sender, EventArgs e) + { + + } + } } diff --git a/Report Runner/Advantage Final/Options.resx b/Report Runner/Advantage Final/Options.resx index 1af7de1..71968ae 100644 --- a/Report Runner/Advantage Final/Options.resx +++ b/Report Runner/Advantage Final/Options.resx @@ -117,4 +117,10 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 17, 17 + + + 137, 17 + \ No newline at end of file diff --git a/Report Runner/Advantage Final/Properties/Resources.Designer.cs b/Report Runner/Advantage Final/Properties/Resources.Designer.cs index 082c862..553f5a7 100644 --- a/Report Runner/Advantage Final/Properties/Resources.Designer.cs +++ b/Report Runner/Advantage Final/Properties/Resources.Designer.cs @@ -1,14 +1,14 @@ //------------------------------------------------------------------------------ // // This code was generated by a tool. -// Runtime Version:4.0.30319.34209 +// Runtime Version:4.0.30319.42000 // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. // //------------------------------------------------------------------------------ -namespace Report_Runner.Properties { +namespace Advantage_Final.Properties { using System; @@ -39,7 +39,7 @@ namespace Report_Runner.Properties { internal static global::System.Resources.ResourceManager ResourceManager { get { if (object.ReferenceEquals(resourceMan, null)) { - global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Report_Runner.Properties.Resources", typeof(Resources).Assembly); + global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Advantage_Final.Properties.Resources", typeof(Resources).Assembly); resourceMan = temp; } return resourceMan; diff --git a/Report Runner/Advantage Final/Properties/Settings.Designer.cs b/Report Runner/Advantage Final/Properties/Settings.Designer.cs index 8458625..9eec931 100644 --- a/Report Runner/Advantage Final/Properties/Settings.Designer.cs +++ b/Report Runner/Advantage Final/Properties/Settings.Designer.cs @@ -1,18 +1,18 @@ //------------------------------------------------------------------------------ // // This code was generated by a tool. -// Runtime Version:4.0.30319.34209 +// Runtime Version:4.0.30319.42000 // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. // //------------------------------------------------------------------------------ -namespace Report_Runner.Properties { +namespace Advantage_Final.Properties { [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "10.0.0.0")] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "12.0.0.0")] internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase { private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); diff --git a/Report Runner/Report Runner.sln b/Report Runner/Report Runner.sln index 91cc89d..bba5554 100644 --- a/Report Runner/Report Runner.sln +++ b/Report Runner/Report Runner.sln @@ -1,13 +1,25 @@  Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio 2013 -VisualStudioVersion = 12.0.31101.0 +VisualStudioVersion = 12.0.30501.0 MinimumVisualStudioVersion = 10.0.40219.1 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Advantage Final", "Advantage Final\Advantage Final.csproj", "{1F135F26-23F8-4EA6-B000-9D22FBE1B273}" EndProject Project("{54435603-DBB4-11D2-8724-00A0C9A8B90C}") = "Setup2", "Setup2\Setup2.vdproj", "{3B803B90-204A-4AA1-B42B-EF8AE9DEF84A}" EndProject Global + GlobalSection(TeamFoundationVersionControl) = preSolution + SccNumberOfProjects = 3 + SccEnterpriseProvider = {4CA58AB2-18FA-4F8D-95D4-32DDF27D184C} + SccTeamFoundationServer = https://ideastoaction.visualstudio.com/defaultcollection + SccLocalPath0 = . + SccProjectUniqueName1 = Advantage\u0020Final\\Advantage\u0020Final.csproj + SccProjectName1 = Advantage\u0020Final + SccLocalPath1 = Advantage\u0020Final + SccProjectUniqueName2 = Setup2\\Setup2.vdproj + SccProjectName2 = Setup2 + SccLocalPath2 = Setup2 + EndGlobalSection GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|x86 = Debug|x86 Release|x86 = Release|x86 diff --git a/Report Runner/Setup2/Setup2.vdproj b/Report Runner/Setup2/Setup2.vdproj index 106e772..3ace949 100644 --- a/Report Runner/Setup2/Setup2.vdproj +++ b/Report Runner/Setup2/Setup2.vdproj @@ -7,10 +7,10 @@ "LanguageId" = "3:1033" "CodePage" = "3:1252" "UILanguageId" = "3:1033" -"SccProjectName" = "8:" -"SccLocalPath" = "8:" -"SccAuxPath" = "8:" -"SccProvider" = "8:" +"SccProjectName" = "8:SAK" +"SccLocalPath" = "8:SAK" +"SccAuxPath" = "8:SAK" +"SccProvider" = "8:SAK" "Hierarchy" { "Entry" @@ -27,22 +27,10 @@ } "Entry" { - "MsmKey" = "8:_8F37A8A0D508172CB4126389173C134F" - "OwnerKey" = "8:_773F541839744F2D82BD24506B6AD655" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { "MsmKey" = "8:_UNDEFINED" "OwnerKey" = "8:_773F541839744F2D82BD24506B6AD655" "MsmSig" = "8:_UNDEFINED" } - "Entry" - { - "MsmKey" = "8:_UNDEFINED" - "OwnerKey" = "8:_8F37A8A0D508172CB4126389173C134F" - "MsmSig" = "8:_UNDEFINED" - } } "Configurations" { @@ -158,37 +146,6 @@ "IsDependency" = "11:FALSE" "IsolateTo" = "8:" } - "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_8F37A8A0D508172CB4126389173C134F" - { - "AssemblyRegister" = "3:1" - "AssemblyIsInGAC" = "11:FALSE" - "AssemblyAsmDisplayName" = "8:Advantage.Data.Provider, Version=11.10.2.1, Culture=neutral, PublicKeyToken=e33137c86a38dc06, processorArchitecture=MSIL" - "ScatterAssemblies" - { - "_8F37A8A0D508172CB4126389173C134F" - { - "Name" = "8:Advantage.Data.Provider.dll" - "Attributes" = "3:512" - } - } - "SourcePath" = "8:Advantage.Data.Provider.dll" - "TargetName" = "8:" - "Tag" = "8:" - "Folder" = "8:_A7687A1270734216981836A33AC6DA62" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:TRUE" - "IsDependency" = "11:TRUE" - "IsolateTo" = "8:" - } } "FileType" { @@ -795,7 +752,7 @@ { "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_773F541839744F2D82BD24506B6AD655" { - "SourcePath" = "8:..\\Advantage Final\\obj\\x86\\Release\\Report Runner.exe" + "SourcePath" = "8:..\\Advantage Final\\obj\\x86\\Debug\\Report Runner.exe" "TargetName" = "8:" "Tag" = "8:" "Folder" = "8:_A7687A1270734216981836A33AC6DA62"