Skip to content

Commit 94b8723

Browse files
committed
Removed unused code lines
1 parent 26f74cb commit 94b8723

File tree

4 files changed

+13
-16
lines changed

4 files changed

+13
-16
lines changed

VB/App_Data/ScriptHelp.sdf

0 Bytes
Binary file not shown.

VB/ScriptHelp.vbproj

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -249,9 +249,7 @@
249249
<Compile Include="TaskPane\GraphData.Designer.vb">
250250
<DependentUpon>GraphData.vb</DependentUpon>
251251
</Compile>
252-
<Compile Include="TaskPane\GraphData.vb">
253-
<SubType>UserControl</SubType>
254-
</Compile>
252+
<Compile Include="TaskPane\GraphData.vb" />
255253
<Compile Include="TaskPane\Script.Designer.vb">
256254
<DependentUpon>Script.vb</DependentUpon>
257255
</Compile>
@@ -313,7 +311,9 @@
313311
</Compile>
314312
</ItemGroup>
315313
<ItemGroup>
316-
<EmbeddedResource Include="Ribbon.xml" />
314+
<EmbeddedResource Include="Ribbon.xml">
315+
<SubType>Designer</SubType>
316+
</EmbeddedResource>
317317
</ItemGroup>
318318
<ItemGroup>
319319
<COMReference Include="SSCE">

VB/Scripts/ErrorHandler.vb

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,10 @@ Namespace Scripts
2828
Dim currentFileName As String = "" 'AssemblyInfo.GetCurrentFileName()
2929
Dim errorMessageDescription As String = ex.ToString()
3030
errorMessageDescription = System.Text.RegularExpressions.Regex.Replace(errorMessageDescription, "\r\n+", " ")
31-
'the carriage returns were messing up my log file
3231
Dim msg As String = "Contact your system administrator. A record has been created in the log file." + Environment.NewLine
3332
msg += (Convert.ToString("Procedure: ") & currentProcedure) + Environment.NewLine
3433
msg += "Description: " + ex.ToString() + Environment.NewLine
35-
'log.[Error](Convert.ToString((Convert.ToString((Convert.ToString("[PROCEDURE]=|") & currentProcedure) + "|[USER NAME]=|" + Environment.UserName + "|[MACHINE NAME]=|" + Environment.MachineName + "|[FILE NAME]=|") & currentFileName) + "|[DESCRIPTION]=|") & errorMessageDescription)
34+
'log.Error("[PROCEDURE]=|" + currentProcedure + "|[USER NAME]=|" + Environment.UserName + "|[MACHINE NAME]=|" + Environment.MachineName + "|[DESCRIPTION]=|" + errorMessageDescription)
3635
If isSilent = False Then
3736
MessageBox.Show(msg, "Unexpected Error", MessageBoxButtons.OK, MessageBoxIcon.[Error])
3837
End If

VB/Scripts/Ribbon.vb

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
Option Strict Off 'late binding on Excel object
22
Option Explicit On
33

4-
'Imports System.Diagnostics
5-
'Imports System.IO.Path
6-
'Imports System.Runtime.InteropServices
7-
'Imports Microsoft.Office.Tools.Ribbon
8-
'Imports Excel = Microsoft.Office.Interop.Excel
9-
'Imports System.Windows
4+
Imports System.Diagnostics
5+
Imports System.IO.Path
6+
Imports System.Runtime.InteropServices
7+
Imports Microsoft.Office.Tools.Ribbon
8+
Imports Excel = Microsoft.Office.Interop.Excel
9+
Imports System.Windows
1010
Imports System.Windows.Forms
1111
Imports ScriptHelp.Scripts
1212

@@ -28,7 +28,6 @@ Namespace Scripts
2828
Public Shared myTableData As TableData
2929
Public Shared myTaskPaneTableData As Microsoft.Office.Tools.CustomTaskPane
3030

31-
3231
'Public NotInheritable Class AppVariables
3332
Public Class AppVariables
3433
Private Sub New()
@@ -168,10 +167,9 @@ Namespace Scripts
168167
Case Is = "txtCopyright"
169168
Return "© " & My.Application.Info.Copyright.ToString
170169
Case Is = "txtDescription", "btnDescription"
171-
Dim AppVersion As String = My.Application.Info.Version.Major & "." & My.Application.Info.Version.Minor & "." & My.Application.Info.Version.Build & "." & My.Application.Info.Version.Revision
172-
Return My.Application.Info.Title.ToString.Replace("&", "&&") & Space(1) & AppVersion
170+
Dim version As String = My.Application.Info.Version.Major & "." & My.Application.Info.Version.Minor & "." & My.Application.Info.Version.Build & "." & My.Application.Info.Version.Revision
171+
Return My.Application.Info.Title.ToString.Replace("&", "&&") & Space(1) & version
173172
Case Is = "txtReleaseDate"
174-
'Dim dteCreateDate As DateTime = System.IO.File.GetLastWriteTime(My.Application.Info.DirectoryPath.ToString & "\" & My.Application.Info.AssemblyName.ToString & ".dll") 'get creation date
175173
Return My.Settings.App_ReleaseDate.ToString("dd-MMM-yyyy hh:mm tt")
176174
Case Else
177175
Return String.Empty

0 commit comments

Comments
 (0)