title: Setting MaximumLength on a StringLengthAttribute in code
body: <p>I'm working on some code which use DataAnnotation attributes on viewmodels, and overrides some of the attributes programmatically under certain circumstances.</p>
  
  <p>Changing <code>ErrorMessage</code> on various types of <code>ValidationAttributes</code>, no problem.</p>
  
  <p>Changing <code>DataFormatString</code> on <code>DisplayFormatAttributes</code>, no problem.</p>
  
  <p>Changing <code>MinimumLength</code> on a <code>StringLengthAttribute</code>, no problem. But.. <code>MaximumLength</code> does not have a public setter!?</p>
  
  <p>Is there any reason why this one property stands out as having a private setter, when all around it are public? Is there any workaround I can use to programmatically change the maximum length of a <code>StringLengthAttribute</code>?</p>