For Next loop, you have to perform a number of sets of code multiple times. The syntax is as follows:
For counter = Initial_value to Finite_value [step increment]
Statements
Next
The For statement specifies the counter variable and its initial and limited value. The next statement increases the fight against a variable. Can
The selected step keyword allows you to specify counter variables by adding or decreasing values.
There is a very simple example:
<%@ language= "VBScript"%>
<%
For i = 0 "Step 2" use I as a counter
Response.Write ("The number is" & I & "<br/>")
Next
%>
Complex instances
Select Actionselect alltry it<%@ language= "VBScript"%>
<%
Response.Write ("Response.Write ("<table border=2 width=50%")
For i = 1 to 9 ' It is the outer loop
Response.Write ("<tr>")
Response.Write ("<td>" & I & "</td>")
For j = 2 to 9 ' inner loop
Response.Write ("<td>" & I * J & "</td>")
Next ' Repeat the code and move on to the next value of J
Response.Write ("</tr>")
Next ' Repeat the code and move on to the next value of I
Response.Write ("</table>")
%>