Results 1 to 4 of 4

Thread: format string

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Jun 1999
    Location
    ma,usa
    Posts
    485
    How do I format a big long string thats stuck in a variable to insert a character every so many characters.

    Suedo code:
    function(1ZillionCharacterString,",",5) returns XXXXX,XXXXX,XXXXX,XXXXX,...

  2. #2
    Guest
    This what you want?

    Code:
    ZillionCharacterString = "1000000000000000000000000"
    MsgBox Format(ZillionCharacterString, "#####,#####,#####,#####,#####")

  3. #3

    Thread Starter
    Hyperactive Member
    Join Date
    Jun 1999
    Location
    ma,usa
    Posts
    485
    Hi Mat,
    I don't want to format it that way because I would be making #'s forever and I'd also need to know the string length. Isn't there a function to do this?

  4. #4
    Guest
    To find out a string's length, use the Len function.

    Code:
    Msgbox Len("MyText")

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width