+ Reply to Thread
Results 1 to 4 of 4

Splitting Cells

  1. #1
    Registered User
    Join Date
    11-18-2008
    Location
    USA
    Posts
    54

    Splitting Cells

    Hello,

    I have a spreadsheet full of data like the spreadsheet above. I get this spreadsheet monthly and would like to be able to have it split up with a macro instead of having to do it manually.

    I would like the results to just have everything with a Q: be in its own cell, and all of the data after the A: to be deleted.

    Can someone help me out?

    Thanks to anyone who can help.
    Attached Files Attached Files

  2. #2
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,482

    Re: Splitting Cells

    You could use text to columns and set Q as the delimiter, unfortunately the Q disappears

  3. #3
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Splitting Cells

    You could split on the line feed character. Do Data > Text to columns, select Delimited, Next, in the Other box press and hold the Alt key, and on the NUMERIC keypad type 0010 (the code for a line feed), Finish. Then delete the "A" columns.

    Once you get that down pat, record a macro doing it and we'll help clean it up.
    Entia non sunt multiplicanda sine necessitate

  4. #4
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: Splitting Cells

    Hello b50,

    This macro places each question in an individual cell along with "A:" (an empty answer). There is button on the worksheet to run the macro. Here is the macro code..
    Please Login or Register  to view this content.
    Attached Files Attached Files
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

+ 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