none
Synchronizing Word text RRS feed

  • Question

  • I am writing a program to detect illegal single quotes by storing document text into a string, searching for single quotes, and then processing them. I find the single quotes all right, but when I use the position in the string to create a range and select the offending single quote in the document, it selects an entirely different character. I believe that the Word document contains formatting characters that are not copied into the text string so that the selection is out of synchronization with the text. Is there a simple way to relate a character in the text to the corresponding character in the document?
    Friday, October 13, 2017 7:19 PM

All replies

  • Hello,

    This forum is for Office JavaScript API. Are your developing with Office JS API? 

    What code are you using now?

    Regards,

    Celeste


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Monday, October 16, 2017 2:18 AM
    Moderator