Visual Basic 6 Tutorial => Do Loop
Có thể bạn quan tâm
Visual Basic 6
- Getting started with Visual Basic 6
- Basic Syntax
- Do Loop
- for loop
- if / else statement
- Select Case Statement
- Function Procedures
- Installing VB6 on Windows 10
- Variables
Visual Basic 6
- Getting started with Visual Basic 6
- Basic Syntax
- Do Loop
- for loop
- if / else statement
- Select Case Statement
- Function Procedures
- Installing VB6 on Windows 10
- Variables
Fastest Entity Framework Extensions
Bulk Insert Bulk Delete Bulk Update Bulk MergeExample
Another common type of loop in Visual Basic is the DO loop, which would run a piece of code continuously until it is told to stop. On the contrary of some other loops whereby indexes are used to stop the process, in this particular loop, it should be told to stop.
A simple example illustrating the loop is as follows
Dim iIndex1 As Integer iIndex1 = 1 Do Debug.Print iIndex1 iIndex1 = iIndex1 + 1 If iIndex1 = 10 Then Exit Do End If LoopThe above piece of code will take an Index, initialized to 1, and increment it. A Debug.Print will help print the index to rack the loop. On each loop, the code will verify if the index has reached 10 and if and only if the condition is true, the Exit Do will be executed, which will stop the loop.
Got any Visual Basic 6 Question?
Ask any Visual Basic 6 Questions and Get Instant Answers from ChatGPT AI: ChatGPT answer me!
SUPPORT & PARTNERS - Advertise with us
- Contact us
- Cookie Policy
- Privacy Policy
Get monthly updates about new articles, cheatsheets, and tricks.
Subscribe Cookie This website stores cookies on your computer. We use cookies to enhance your experience on our website and deliver personalized content. For more details on our cookie usage, please review our Cookie Policy and Privacy Policy Accept all Cookies Leave this websiteTừ khóa » Visual Basic 6.0 While Loop Example
-
Loops (Repetition Structures) In Visual Basic 6
-
VB 6 While Loop - Notesformsc
-
While...End While Statement - Visual Basic - Microsoft Docs
-
Do While Loop In Vb6.0 - CodeProject
-
Using Visual Basic 6 -- Ch 10 -- Working With Loops
-
Visual Basic (VB) Do While Loop - Tutlane
-
Visual Basic While Loop - Tutlane
-
[PDF] Existing Loop 1. Do While Condition Loop
-
Lesson 9 : Looping - Visual Basic Tutorial
-
While Loop, Do While Loop, Do Until Loop, While End While - VB.NET
-
While Loop With Example In Visual Basic 6.0 - YouTube
-
VB 6.0 Example 4 (do While...Loop) - YouTube
-
Looping Control Statements In VB 6.0 | Do While Loop - YouTube
-
Visual Basic/Loops - Wikibooks, Open Books For An Open World