J
Jeremy S
In a Web Forms application I present users with a list of items - each of
which the user is to assign to a grid. The grid is N rows by 3 columns.
The users enter the desired target cell for each list item by specifying two
integer values - one for the row number and the other for the column number
of the target cell.
When users submit the form for processing I need to validate that the
following are all true:
Please note that I can tackle 1 and 2 on my own as well as test for data
type, etc (will use RegEx). What I'd appreciate suggestions is how to
accomplish #3:
1. No value specified for RowNumber is larger than the total possible number
of rows.
2. Each value for ColumnNumber is 1, 2, or 3 (never zero, and never larger
than 3)
3. No cell is specified more than once (i.e., every combination of RowNumber
and ColumnNumber entered must be unique.
While this is a Web application, I'll be processing this on the server
during a postback.
Thanks.
which the user is to assign to a grid. The grid is N rows by 3 columns.
The users enter the desired target cell for each list item by specifying two
integer values - one for the row number and the other for the column number
of the target cell.
When users submit the form for processing I need to validate that the
following are all true:
Please note that I can tackle 1 and 2 on my own as well as test for data
type, etc (will use RegEx). What I'd appreciate suggestions is how to
accomplish #3:
1. No value specified for RowNumber is larger than the total possible number
of rows.
2. Each value for ColumnNumber is 1, 2, or 3 (never zero, and never larger
than 3)
3. No cell is specified more than once (i.e., every combination of RowNumber
and ColumnNumber entered must be unique.
While this is a Web application, I'll be processing this on the server
during a postback.
Thanks.