13 Replies Latest reply on Feb 7, 2017 3:42 PM by Obi-wan Kenobi

    Index entries contain invalid characters

    GJ du Toit Level 1

      I've inserted 11000 index markers in text files (cases and statutes in a big law book), and on import they display correctly in the index panel. But when I want to generate the index, the dreaded message comes up:

       

      "The index could not be generated. One or more index entries contain invalid characters. Please delete any invalid characters from the index entries."

       

      From what I've been able to gather from discussions found elsewhere, this is sometimes caused by invalid characters inserted as separators etc. in the "Generate Index" dialog, but it's not those, I've checked.

       

      Also, most of the entries are very similar (cases and statutes), and I've tried generating an index with just a few pages of the same text containing the same type of entries, and then it works fine.

       

      Any suggestions?

        • 1. Re: Index entries contain invalid characters
          John Hawkinson Level 5

          Make a copy of your document.

           

          Then, start chopping it up. Delete half the story (or half the pages). Problem still there?

          Delete half again? Repeat, repeat, repeat.

          Isolate to the text causing the problem.

           

          Maybe start by making sure it actually works with a single sentence, though.

          • 2. Re: Index entries contain invalid characters
            GJ du Toit Level 1

            Thanks John!

             

            In fact, shortly after posting my query, I went for a walk, thought about it, and decided on the same plan.

            I split the document again and again, and when I was down to the final two pages, I had a look at the index entries left over, and hey! came across:

             

             

             

            Laë�.��ë.�.��ct 66 of 1995

            which should have read

            Labour Relations Act 66 of 1995"

             

            Fixed that, and it worked fine. I'm enormously relieved. Thank you very much for your response.

             

            But hell, can't the error message be improved to tell you what the problem characters are (so you can search for them), or where  they are, or both.

            • 3. Re: Index entries contain invalid characters
              macinbytes Level 4

              The index interface is the geeky younger brother who doesn't get a lot of attention. I've learned to hate it when spanning multiple files in a book and took it off my Christmas Card list when I had a book use more than a couple hundred entries.

               

              Beats hand keying an index with a sales rep breathing over your shoulder though.

              • 4. Re: Index entries contain invalid characters
                John Hawkinson Level 5
                Fixed that, and it worked fine. I'm enormously relieved. Thank you very much for your response.

                 

                But hell, can't the error message be improved to tell you what the problem characters are (so you can search for them), or where  they are, or both.

                Indeed, I would consider it a bug, but I'm not sure that the InDesign team would. I would recommend you open a support case and try to get them to declare it a bug and get a bug number. http://adobe.com/go/supportportal. If you use the adobe.com/go/wish interface, well, you won't get a bug number and I suspect it'll be a fair bit less likely to get fixed.

                1 person found this helpful
                • 5. Re: Index entries contain invalid characters
                  GJ du Toit Level 1

                  The index interface is the geeky younger brother who doesn't get a lot of attention. I've learned to hate it when spanning multiple files in a book and took it off my Christmas Card list when I had a book use more than a couple hundred entries.

                   

                  Beats hand keying an index with a sales rep breathing over your shoulder though.

                  You’re right, and I’m worried about it. This is a looseleaf 2-volume job (1000 pages per volume) that is revised twice a year, and the indexes (Index of Cases, Index of Statutes, General Index) are regenerated and reissued each time. So there’s no option but to use embedded indexes.

                   

                  I inherited the job some years ago in Ventura, which is suited very well to this kind of work and handled the heavy footnotes and three separate indexes flawlessly. However, the bugs and instability eventually drove me crazy. I would love to have migrated this job to FrameMaker (which has the best indexing around, especially with the IxGen add-in), but FrameMaker’s footnotes are pathetic (can’t keep the note on the same page as the reference; can’t break a footnote across pages).

                   

                  So I had little choice but to do it in InDesign. I’ve had problems before with missing entries in InDesign indexes generated from multifile books, but I sort of got the impression that it was fixed in one of the CS3 updates: I did some indexes later that seemed to be okay, with no obvious missing entries (on fairly small books, admittedly). Do you know whether that is indeed the case? Also, do you know whether CS5 handles indexing any better than CS3 (I’m doing this in CS3 although I’ve got CS5: had problems with exports to Tagged Text in CS5 which I hadn’t experienced in CS3, and so did this job in CS3 to avoid those.)

                  • 6. Re: Index entries contain invalid characters
                    GJ du Toit Level 1

                    Indeed, I would consider it a bug, but I'm not sure that the InDesign team would. I would recommend you open a support case and try to get them to declare it a bug and get a bug number. http://adobe.com/go/supportportal.

                    Thanks again, John. I've opened a support case. 
                    • 7. Re: Index entries contain invalid characters
                      John Hawkinson Level 5

                      Making better user interfacs is well within the realm of scripting, and not necessarily even too hard.

                      But this comment struck me:

                       

                      Also, do you know whether CS5 handles indexing any better than CS3 (I’m doing this in CS3 although I’ve got CS5: had problems with exports to Tagged Text in CS5 which I hadn’t experienced in CS3, and so did this job in CS3 to avoid those.)

                      What goes wrong?

                      • 8. Re: Index entries contain invalid characters
                        GJ du Toit Level 1

                        . . . problems with exports to Tagged Text in CS5

                        >> What goes wrong?

                         

                        Footnotes move.

                        In the exported text, a footnote might move to a position earlier in the same paragraph. An example:

                         

                        In the Smith1 case, the court followed the precedent set in the Jones2 case.

                        1 Smith v Smith 2011 ABC 123 etc.

                        2 Jones v Jones 2011 DEF 435 etc.

                         

                        (With the footnotes codes replaced with {} to reduce clutter) this should export as:

                        In the Smith{Smith v Smith 2011 ABC 123 etc.} case, the court followed the Jones{Jones v Jones 2011 DEF 435 etc.} case.

                         

                        But it may come out as:

                        In the Smith{Smith v Smith 2011 ABC 123 etc.}{Jones v Jones 2011 DEF 435 etc.} case, the court followed the Jones case.

                           or as:

                        {Smith v Smith 2011 ABC 123 etc.}{Jones v Jones 2011 DEF 435 etc.}In the Smith case, the court followed the Jones case.

                         

                        And on re-import, the footnote references are, of course, in the wrong place. But the footnote numbers remain correct, and so the footnotes at the bottom of the page are correct, because the footnotes remain in the same order and in the same paragraph, only sometimes move to positions earlier in that paragraph.

                         

                        I haven't been able to pin it down: when and where exactly it happens. It seemed to be haphazard and more common in some documents than others. I need to spend some time experimenting, and checking re-imported footnotes of a sample document against the original, but, having had to get the work done, I've simply opted out and used CS3 for documents where I might have to export to text and re-import.

                        • 9. Re: Index entries contain invalid characters
                          John Hawkinson Level 5

                          Curious. Well, I do think you should track it down.

                           

                          At the least, figure out if it is on import or on export -- have you looked at the tagged text file in a text editor?

                          • 10. Re: Index entries contain invalid characters
                            Erick Wand

                            Thanks for the chop suggestion. We've had to resort to this in the past with other problems, but had not done that for many years. I was able find the errant invalid character in the 121 page doc I was trying to generate an Index. The invalid character was imported out of Word from a document I did not type, so I had no idea what the problem was.

                            • 11. Re: Index entries contain invalid characters
                              Laubender Adobe Community Professional & MVP

                              Erick Wand wrote:

                              … The invalid character was imported out of Word from a document I did not type …

                              Hi Erick,

                              could you give the Unicode number of that character?

                              So others can prepare if they import Word doc or docx files.

                               

                              Could it be found by Text Find/Replace or GREP Find/Replace?

                              Maybe also important since this thread is about 6 years old:
                              What is you exact version of InDesign on what OS ?

                               

                              Regards,
                              Uwe

                              • 12. Re: Index entries contain invalid characters
                                Erick Wand Level 1

                                The invalid character is a nonbreaking space character in MS Word. As part of the imported text it shows up as a carrot in InDesign when hidden characters is on. When used as part of an Index Reference, it shows as a carrot S or ^S. You can search with ^S in InDesign, but the only time it is an issue in when it is part of an Index Reference. My InDesign Doc us full of these nonbreaking spaces from many Word Docs. I only had an issue with one.