From 3db0c6fa3cc925754692d75d441cd38fb80a4bc3 Mon Sep 17 00:00:00 2001 From: Roy Ben Shabat Date: Tue, 3 Nov 2020 15:50:45 +0200 Subject: Fixed issue with PPC export multiple jobs invalid characters. --- .../PPC/Modules/Tango.PPC.Storage/ViewModels/MainViewVM.cs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/ViewModels') diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/ViewModels/MainViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/ViewModels/MainViewVM.cs index b9d59334c..9b22fcdb5 100644 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/ViewModels/MainViewVM.cs +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/ViewModels/MainViewVM.cs @@ -22,7 +22,6 @@ namespace Tango.PPC.Storage.ViewModels { private bool _allow_exit; private ExplorerFileItem _selectedItem; - private static char[] _invalidChars = System.IO.Path.GetInvalidFileNameChars(); private String _currentPath; public String CurrentPath @@ -238,10 +237,7 @@ namespace Tango.PPC.Storage.ViewModels if (text != null) { - foreach (var c in _invalidChars) - { - text = text.Replace(c.ToString(), ""); - } + text = text.ToValidFileName(); _fileName = text; RaisePropertyChanged(nameof(FileName)); -- cgit v1.3.1