+ Reply to Thread
Results 1 to 5 of 5

Adding in Information in the middle and end of the string

  1. #1
    Forum Contributor
    Join Date
    03-26-2014
    Location
    Kentucky
    MS-Off Ver
    Excel 2013
    Posts
    128

    Adding in Information in the middle and end of the string

    I have a column labeled with patient ID's and I need to add in a few quality control checkpoints. For example:

    Column A
    12134
    12355
    24345
    13523
    12312
    14321

    I would like to add into the data a DOA2 in the center and a DOA3 at the end to look like this:

    Column A
    12134
    12355
    24345
    DOA2
    13523
    12312
    14321
    DOA3

    What code would allow me to do this?

  2. #2
    Forum Contributor Jack7774's Avatar
    Join Date
    08-31-2012
    Location
    Georgia, US
    MS-Off Ver
    Excel 2010
    Posts
    576

    Re: Adding in Information in the middle and end of the string

    Try this. Make sure you have the first cell with data selected in the column you wish to add the mid DOA2 and ending DOA3 too.

    Please Login or Register  to view this content.
    Thank those who have helped you by clicking the Star * below their name and please mark your post [SOLVED] if it has been answered satisfactorily.

  3. #3
    Forum Contributor
    Join Date
    03-26-2014
    Location
    Kentucky
    MS-Off Ver
    Excel 2013
    Posts
    128

    Re: Adding in Information in the middle and end of the string

    Wow thanks but how can I get it to move column B as well? I don't want text beside the DOA's in column B, just a blank space.

  4. #4
    Forum Contributor Jack7774's Avatar
    Join Date
    08-31-2012
    Location
    Georgia, US
    MS-Off Ver
    Excel 2010
    Posts
    576

    Re: Adding in Information in the middle and end of the string

    You can run the same macro when you have a cell with data selected in column B and it will work just the same as in column A. I am not following what you mean by test beside the DOA's in column B, just a blank space. Do you mean you just want DOA and no numbers?

  5. #5
    Forum Contributor Jack7774's Avatar
    Join Date
    08-31-2012
    Location
    Georgia, US
    MS-Off Ver
    Excel 2010
    Posts
    576

    Re: Adding in Information in the middle and end of the string

    Any updates?

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Remove middle name for end of a name string
    By maacmaac in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 08-30-2022, 04:44 PM
  2. Sort by text in the middle of a string
    By javeds in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-08-2014, 12:32 PM
  3. counting characters in the middle of a string
    By DCRAIG3389 in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 07-19-2013, 06:26 PM
  4. [SOLVED] Split a name string into first name , middle initial and last name
    By Lady_Shaz in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 01-24-2013, 01:39 AM
  5. [SOLVED] Adding variable to middle of string for querytables.add (to import daily files)
    By JP Romano in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-12-2012, 01:25 PM

Tags for this Thread

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