Hi Chas, the code was originally created by Macropod so I'm not sure how to comment the code itself - I found the code on VBA Express from a post back in 2021. I know the code should auto insert a cross reference for numbered styles e.g. Heading Styles, but unfortunately the code is cross referencing numbers that are not part of numbered styles as seen in the image I posted. Sorry I can't be of much help as I'm sure sure what each line of Macropod's code does.