Search
 
SCRIPT & CODE EXAMPLE
 

CSHARP

c# remove xml invalid characters

// remove xml invalid chars plus additioan replace for space and &
 static string RemoveInvalidXmlChars(string text)
        {
            var validXmlChars = text.Where(ch => XmlConvert.IsXmlChar(ch)).ToArray();
            return new string(validXmlChars).Replace(" ","").Replace("&","");
        }
Comment

PREVIOUS NEXT
Code Example
Csharp :: C# show text in another form 
Csharp :: create blazor server 
Csharp :: unity rollaball 
Csharp :: join string c# 
Csharp :: wpf binding object get value 
Csharp :: demand a Security action c# 
Csharp :: set request size c# 
Csharp :: dictionary all key where value c# 
Csharp :: c# lambda group by multiple columns 
Csharp :: c# code to check anagram 
Csharp :: unity gui button width 
Csharp :: C# How to display text in console 
Csharp :: remove substring from string c# 
Csharp :: load information with txt file to uwp c# 
Csharp :: Test for even Number 
Csharp :: disable version header c# 
Csharp :: c# timer single tick 
Csharp :: self referencing loop detected for property entity framework 
Csharp :: select from list where not in other list c# 
Csharp :: car controller unity 
Csharp :: convert list of string to dictionary 
Csharp :: elasticsearch nested aggregation in c# 
Csharp :: c# getting response content from post 
Csharp :: c# code examples 
Csharp :: if else c# 
Csharp :: c# async task constructor 
Csharp :: get camera position unity 
Csharp :: active form 
Csharp :: c# check multiple variables for null 
Csharp :: Unity Scene Load by BuildIndex 
ADD CONTENT
Topic
Content
Source link
Name
1+7 =