Skip to content

Commit

Permalink
Fix messages in issue #70
Browse files Browse the repository at this point in the history
  • Loading branch information
paul1956 committed Feb 16, 2021
1 parent 6aa9587 commit 8530c64
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 8 deletions.
6 changes: 3 additions & 3 deletions CSharpToVB/CSharpToVB.vbproj
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@
<Product>CSharp To VB Converter</Product>
<Copyright>Copyright (c) .NET Foundation and Contributors</Copyright>
<PackageId>CSharp To VB Converter</PackageId>
<AssemblyVersion>5.0.2.5</AssemblyVersion>
<FileVersion>5.0.2.5</FileVersion>
<Version>5.0.2.5</Version>
<AssemblyVersion>5.0.2.6</AssemblyVersion>
<FileVersion>5.0.2.6</FileVersion>
<Version>5.0.2.6</Version>
<EnableNETAnalyzers>true</EnableNETAnalyzers>
<EnforceCodeStyleInBuild>true</EnforceCodeStyleInBuild>
</PropertyGroup>
Expand Down
6 changes: 3 additions & 3 deletions CSharpToVB/Utilities/ConvertProjectFileUtilities.vb
Original file line number Diff line number Diff line change
Expand Up @@ -207,11 +207,11 @@ Public Module ConvertProjectFileUtilities

Public Function ConvertProjectFile(sourceFilePath As String, ProjectSavePath As String) As String
If String.IsNullOrWhiteSpace(sourceFilePath) Then
Throw New ArgumentException($"'{NameOf(sourceFilePath)}' cannot be null or whitespace", NameOf(sourceFilePath))
Throw New ArgumentException($"'{sourceFilePath}' cannot be null or whitespace", NameOf(sourceFilePath))
End If

If String.IsNullOrWhiteSpace(ProjectSavePath) Then
Throw New ArgumentException($"'{NameOf(ProjectSavePath)}' cannot be null or whitespace", NameOf(sourceFilePath))
Throw New ArgumentException($"'{ProjectSavePath}' cannot be null or whitespace", NameOf(sourceFilePath))
End If

Dim xmlDoc As New XmlDocument With {
Expand All @@ -228,7 +228,7 @@ Public Module ConvertProjectFileUtilities
isDocument = False
End If
If root.Attributes.Count = 0 OrElse Not root.Attributes(0).Value.StartsWith("Microsoft.NET.Sdk", StringComparison.OrdinalIgnoreCase) Then
MsgBox("Project {sourceFilePath} is not an SDK project, the project file will not be converted!", MsgBoxStyle.Information, "Project Coversion Issue")
MsgBox($"Project {sourceFilePath} is not an SDK project, the project file will not be converted!", MsgBoxStyle.Information, "Project Coversion Issue")
Return ""
End If
Dim basePath As String = DestinationFilePath(sourceFilePath, ProjectSavePath)
Expand Down
4 changes: 2 additions & 2 deletions CSharpToVB/Utilities/ProcessProjectUtilities.vb
Original file line number Diff line number Diff line change
Expand Up @@ -284,10 +284,10 @@ Public Module ProcessProjectUtilities
MainForm._cancellationTokenSource).ConfigureAwait(True)
If results.resultsString.Length = 0 Then
If MainForm._cancellationTokenSource.Token.IsCancellationRequested Then
prompt = $"Conversion canceled, {processedProjects} of {totalProjects} projects completed successfully."
prompt = $"Conversion canceled, files in {processedProjects} of {totalProjects} projects completed successfully."
Exit For
Else
prompt = $"Conversion completed, {totalProjects} projects completed successfully."
prompt = $"Conversion completed, files in {totalProjects} projects completed successfully."
End If
Else
prompt = $"Conversion canceled because {results}, {processedProjects} of {totalProjects} projects completed successfully."
Expand Down
3 changes: 3 additions & 0 deletions ReadMe.MD
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@ Microsoft.Dotnet.XUnitExtensions which provides ConditionalFact and PlatformSpec
Any changes to CSharpToVB application needs to change the version information in the project file **AND** in MyProject/AssemblyInfo.vb until Visual Studio is able to general file automatically for a WinForms application.

## What's New in this release
New in 5.0.2.6/5.0.1.8
- Fix messages for issue #70

New in 5.0.2.5/5.0.1.8
- Fix version checking to correctly use Version.Parse and logic for detecting Generated Code

Expand Down

0 comments on commit 8530c64

Please sign in to comment.