Wednesday, July 15, 2009

[vb6] How to create list of same items?

Suppose you want this result:
    abc,abc,abc,abc,abc
But you don't want to create it in the Do or For loop. So you can use the following syntax:
    Mid(Replace(5, "~"), "~", ",abc"), 2)

2 comments:

  1. This is WRONG. It really is a good idea to cut and paste from a tested version... like this:
    Debug.Print Mid(Replace(String(5, "~"), "~", ",abc"), 2)

    ReplyDelete