+ Reply to Thread
Results 1 to 2 of 2

Macro to Delete all but first 3 characters

  1. #1
    Registered User
    Join Date
    04-15-2009
    Location
    Victoria, BC
    MS-Off Ver
    Excel 2010
    Posts
    3

    Macro to Delete all but first 3 characters

    Hi,

    I have a table that I am importing into Excel from accounting software. The spreadsheet that contains the imported data has a tab for each month of the year. The column headers in row 1 currently have a three digit location number followed by the location name. The columns are too wide with the full location name.

    I want to include a macro that will run on the active tab in the worksheet to delete all characters in the column headers except for the three digit location number. The very last column contains totals and must be excluded. We are constantly adding new locations and closing old ones, so the number of columns of data will change month by month and I do not want to have to modify the macro when that happens. It must run on the active tab in the worksheet so it can be run on a new tab each month.

    Thanks in advance for your help!

  2. #2
    Forum Expert
    Join Date
    01-15-2007
    Location
    Brisbane, Australia
    MS-Off Ver
    2007
    Posts
    6,591

    Re: Macro to Delete all but first 3 characters

    Hi

    Try

    Please Login or Register  to view this content.
    rylo

+ 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