+ Reply to Thread
Results 1 to 4 of 4

adding space to a string after 10 characters

  1. #1
    Registered User
    Join Date
    10-07-2011
    Location
    N/A
    MS-Off Ver
    Excel 2010
    Posts
    54

    adding space to a string after 10 characters

    Hi there,

    I tried the code but it's not working, I add the code to module1 and create abutton on sheet1 to start testing macro. The data is in range A1. When I call testing macro nothing is happening but if I add =InsertSpaceEveryN(Range("A1").Value, 10) to certain range the code work nicely. What can be the problem?

    Please Login or Register  to view this content.
    thanks,
    Last edited by copythat; 12-06-2011 at 06:00 AM.

  2. #2
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: adding space to a string after 10 characters

    I just ran your test and it seems to work fine.

    Dom
    Last edited by Domski; 12-02-2011 at 10:47 AM.
    "May the fleas of a thousand camels infest the crotch of the person who screws up your day and may their arms be too short to scratch..."

    Use code tags when posting your VBA code: [code] Your code here [/code]

    Remember, saying thanks only takes a second or two. Click the little star to give some Rep if you think an answer deserves it.

  3. #3
    Forum Expert Bob Phillips's Avatar
    Join Date
    09-03-2005
    Location
    Wessex
    MS-Off Ver
    Office 2003, 2010, 2013, 2016, 365
    Posts
    3,284

    Re: adding space to a string after 10 characters

    Please Login or Register  to view this content.

  4. #4
    Registered User
    Join Date
    10-07-2011
    Location
    N/A
    MS-Off Ver
    Excel 2010
    Posts
    54

    Re: adding space to a string after 10 characters

    Thanks Domski and Bob Phillips (for the code),

    It works like a charm!!!
    Last edited by copythat; 12-02-2011 at 11:39 AM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1