+ Reply to Thread
Results 1 to 11 of 11

Want to retain text format

  1. #1
    Registered User
    Join Date
    06-11-2009
    Location
    Pori, Finland
    MS-Off Ver
    Excel 2000
    Posts
    7

    Smile Want to retain text format

    Hi!

    I have a list that looks like this:

    1. Here I have som formatted text.
    2. Here too.
    10. And here.
    110. As well as here.

    The content of each line is in a single cell.

    How do I go about automatically chopping off the number, the dot and the space before the text, but retaining all formattings?

    Hope somebody can help!

    Cheers,
    Baalbek

  2. #2
    Valued Forum Contributor tek9step's Avatar
    Join Date
    05-27-2009
    Location
    London, England
    MS-Off Ver
    MS 365
    Posts
    389

    Re: Want to retain text format

    Can you attach an example !!!


    Cheers !!

    Tek9Step

  3. #3
    Registered User
    Join Date
    06-11-2009
    Location
    Pori, Finland
    MS-Off Ver
    Excel 2000
    Posts
    7

    Re: Want to retain text format

    Sure!

    Here's an example file, the problem is described in this threads first post!

    Baalbek
    Attached Files Attached Files

  4. #4
    Registered User
    Join Date
    06-11-2009
    Location
    Pori, Finland
    MS-Off Ver
    Excel 2000
    Posts
    7

    Re: Want to retain text format

    So nobody's had any luck with this then...?

    Me neither, yet, and I'm actually starting to think this is something you can't do in Excel.

    But then again, a macro that:
    1. went into text editing mode
    2. disregarded the actual content of the cell
    3. deleted from the first character until the first dot
    4. and then deleted one more character
    doesn't sound impossible... but I just can't manage it.

    The reason the second point is there is, I tried to automatically record a macro like this, and ended up with a long list of only the items identical to the first item in the list...

    Yep,
    Baalbek

  5. #5
    Registered User
    Join Date
    06-11-2009
    Location
    Pori, Finland
    MS-Off Ver
    Excel 2000
    Posts
    7

    Re: Want to retain text format

    Yes, using substitute and find was a good idea, but the other part of the problem remains; the formattings (bold, italics, underlined etc.)

    That seems to be some kind of basic issue in excel, which is best highlighted by the example file formatproblem2.xls

    You'll see that as soon as excel picks up text from another cell, it drops all formattings. Do you guys happen to know of a way to keep them in the new cell as well?

    Baalbek

  6. #6
    Registered User
    Join Date
    06-11-2009
    Location
    Pori, Finland
    MS-Off Ver
    Excel 2000
    Posts
    7

    Re: Want to retain text format

    And the file!
    Attached Files Attached Files

  7. #7
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Want to retain text format

    I don't know of any way to keep formatting in XL I'm afraid.

    My suggestion based on your sample...

    Copy data into Word
    Run an Edit -> Replace:
    Replacing: *.[space] (space being you hit space)
    With: [nothing]

    In options check "use wildcard" if not selected by default.

    Copy results back to XL.

    This may/may not work pending your structure of narratives... ie if you have full stops followed by space within the descriptions... in the sample this pattern only occurs after the number ID.

  8. #8
    Registered User
    Join Date
    06-11-2009
    Location
    Pori, Finland
    MS-Off Ver
    Excel 2000
    Posts
    7

    Re: Want to retain text format

    The "replace in word" worked pretty good, but couldn't use "^p" with wildcard checked, which resulted in it deleting everything before each dot, which only left me with the last item in the list!

    But still, the formats are just as important, and seem even to be the bigger problem.

    Baalbek

  9. #9
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Want to retain text format

    I'm not sure I can add anything - based on your original sample file the Word approach works, if you real data is different such that the Word approach outlined does not work we'd need to first see it before we could comment on it.

  10. #10
    Registered User
    Join Date
    06-11-2009
    Location
    Pori, Finland
    MS-Off Ver
    Excel 2000
    Posts
    7

    Re: Want to retain text format

    You're right, Here's a file with reliable examples. Just like the last one, but I actually do have full stops followed by spaces in my material (now included). Quite a lot of them. The numbering in my real material just goes to 250, but I have loads of these files, and would really appreciate it if we could find an automatic function to solve this.

    Baalbek
    Attached Files Attached Files

+ 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