Asp code validating a form

In most cases, there are good rationales for the given conventions.

However, in some cases an arbitrary decision was made to select one convention from a set of reasonable alternatives.

The general rule is that exceptions to the conventions can be made with the approval of the programming team after careful consideration.

asp code validating a form-24

A comment of this sort is generally preceded by a blank line unless it is the first line of an indented block. The comment is wrong if the code changes to use the variable name vt Cur instead of vt without changing the comment.

When reading a comment that doesn't match the code, the question becomes whether the comment is correct or the code is correct.

Assertions are only effective if they are present, which means that they have to be added when writing the code.

Any logic error that is fixed in the code is a good indication that some additional assertions need to be added.

Usually it is the comment that is wrong, but it may take some time to prove that.

In general, do not write comments that have to be maintained, because in the real-world people frequently do not maintain comments.For example, suppose that a procedure includes this code: This code assumes that the value of int Value is between one and three.However, if through some bug, int Value had the value of zero or four, this code doesn't work right. Tracking down why the Msg Box doesn't appear is time consuming.However, this makes the flow of the document unusual for casual reading as some topics are much more technical than others.Always specify the both the lower and upper bound of an array.The other reasonable alternatives to the conventions placed in at the end of a section.

Tags: , ,