Answers for "c# properties making string required"

C#
0

c# properties making string required

using System.ComponentModel.DataAnnotations;

{
  [Required(ErrorMessage = "DocumentType is required.")]
  public string DocumentType 
  { 
      get { return _documentType; }
      set { _documentType = value; }
  }
}
Posted by: Guest on September-16-2020

C# Answers by Framework

Browse Popular Code Answers by Language