Split file into multiple files



  • Greetings! I am working with a large text file (a hymnal ) to import into a presenter software. I can import plain text, but I need to split the hymnal file into individual text files. The hymnal is formatted like this:

    1

    1. song lyrics
    2. song lyrics
    3. song lyrics

    2

    1. song lyrics
    2. song lyrics
    3. song lyrics

    etc.

    the numbers are page numbers without titles, which makes it easy to find where each song begins and ends. The “1.” indicates verses in the songs. Is there a way to automagically export from the main text file and save each song as its own text file?

    I know I can print out only selected text (to printer or pdf)…is it possible to print selected text to a new file? It wouldn’t be automatic but it might be quicker than manually copy/paste and creating hundreds of new documents.

    Thanks!



  • @matt-bjerk

    Sounds like a task for a programming language. Notepad++ itself can do nothing to help, but you could certainly use one of its scripting language plugins to accomplish this.


Log in to reply