try this
return new FaultEntity()
{
Nr = token[0]=="0"?" ":token[0],
...
};
for an integer value
int data = 10102;
string st = data.ToString();
var con = st.Replace('0', ' ');
More Related Contents:
- How do I replace the *first instance* of a string in .NET?
- Replace “\\” with “\” in a string in C#
- Is it safe to check floating point values for equality to 0?
- Is there an alternative to string.Replace that is case-insensitive?
- Replace only some groups with Regex
- How to replace part of string by position?
- String.Replace() vs. StringBuilder.Replace()
- C# String replace with dictionary
- Alternative to multiple String.Replaces [duplicate]
- C# string replace
- Count regex replaces (C#)
- Regex replace multiple groups
- Regex : how to get words from a string (C#)
- Replacing escape characters from JSON
- Nullable types: better way to check for null or zero in c#
- C# Replace bytes in Byte[]
- c# Fastest way to remove extra white spaces
- How to replace the text between two characters in c#
- What is the difference between == and Equals() for primitives in C#?
- How to exit all running threads?
- How to hide some members of an interface
- How to map Win32 types to C# types when using P/Invoke?
- Moq & Interop Types: works in VS2012, fails in VS2010?
- How to detect multiple keys down onkeydown event in wpf?
- The type arguments for method cannot be inferred from the usage
- How to globally set default options for System.Text.Json.JsonSerializer?
- Is TLS 1.1 and TLS 1.2 enabled by default for .NET 4.5 and .NET 4.5.1?
- Unable to change array size in Inspector variable in Unity?
- Validating user input / Give .NET controls status OK or NOK
- LINQ to Entities does not recognize the method ‘System.String ToString()’ method in MVC 4