check if a string is only spaces csharp
Code Example - check if a string is only spaces csharp
if (string.IsNullOrWhiteSpace(yourString))
{
// the string is empty or only spaces
}
if (string.IsNullOrWhiteSpace(yourString))
{
// the string is empty or only spaces
}