+ 1

VB while end while looping please help me

Problem: Create a simple program that will add your name 5 times in the listbox in ascending order idunno how to use string variable in looping but this what i tried Dim counter As Integer =1 Dim Name As String = "Lulu" While counter = Name ListBox1.Items.Add(Name) Name = Name + Name End While i dunnoooo how to use string variable in looping and i also dont really understand the problem please help me

8th Apr 2021, 1:12 PM
shhdhdidjxnxn
shhdhdidjxnxn - avatar
4 Answers
+ 5
I don't know VB. But from what I see here, you should try this: Dim counter As Integer = 1 Dim name As String = "Lulu" While counter <= 5 ListBox1.Items.Add(name) counter = counter + 1 End While
8th Apr 2021, 1:25 PM
Coding Cat
Coding Cat - avatar
+ 1
Thank you so much
8th Apr 2021, 3:29 PM
shhdhdidjxnxn
shhdhdidjxnxn - avatar
0
Dim counter As Integer Dim name As String = "Lulu" for counter = 1 to 5 ListBox1.Items.Add(name) next
6th May 2021, 11:08 PM
Hamed Sedaghat Tinat Rad
Hamed Sedaghat Tinat Rad - avatar
- 1
VS 2015 I am not sure the proper way to write this code. I know that I must start with Do While .......................... Loop But between those two statements I am not sure what to put https://www.myaarpmedicare.work/
13th Sep 2021, 6:23 AM
Bogisichb