October 23, 2018
Hot Topics:

Basics of VB Programming

  • November 20, 2002
  • By Sam Huggill
  • Send Email »
  • More Articles »

The Do..Loop is a good way to loop a certain condition depending on different criteria. e.g.

Msgbox "Hi"

The problem with this code is that it will keep on going forever. You can of course set certain conditions. e.g.

Dim i As Integer
Do While i>0

This code will count down from 10 and when i is 0, the loop ends. Another use of this loop is:

Dim i As Integer
Do Until i=0

This code will continue until i is 0, and then stop.

Page 5 of 6

Comment and Contribute


(Maximum characters: 1200). You have characters left.



Enterprise Development Update

Don't miss an article. Subscribe to our newsletter below.

By submitting your information, you agree that developer.com may send you developer offers via email, phone and text message, as well as email offers about other products and services that developer believes may be of interest to you. developer will process your information in accordance with the Quinstreet Privacy Policy.


Thanks for your registration, follow us on our social networks to keep up-to-date