Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 363
  • Last Modified:

String str1 = str & i possible?

Hello

I want to do something like this here:

Dim str1, str2, str3, str4, str5, i

for i = 0 to 4
str & (i+1) = "Test"
next



In the real app I'm not filling the strings with the same values!
I just want to be able to have str1 as str(i+1) ...

possible?

Thanks

Sven
0
Ruttensoft
Asked:
Ruttensoft
1 Solution
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
better would be to have the str defined as array...
but I guess you have something more complex in mind?
0
 
tolgaongCommented:
You should use arrays instead
try this:

dim str(5) as string
dim i as integer

for i = 0 to 4
   str(i) = "Test"
next
0

Featured Post

Become an Android App Developer

Ready to kick start your career in 2018? Learn how to build an Android app in January’s Course of the Month and open the door to new opportunities.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now