I have the following defined:
public class Menu
{
[DisplayName("Control")]
public int Control { get; set; }
Using it like this:
@Html.TextBoxFor(x => x.Control, new { id = "control" })
Is it possible for me to specify a range for the order? I would like the order to be a
number between 0 and 999.
Also is it possible for me to make the textbox that gets created just have space for three
characters?
use RangeAttribute
For the second question
use StringLengthAttribute
You can also specify a minumun chars length if you want