Check to see if the property already exists.Here is a brief summary of what the function should do, but the full function is below should you find it easier to check that. I've created a function to set the properties I desire (as below), and VBA is throwing no error (even when I remove error handling in the function). I'm trying to set both built-in and custom properties, but for the purpose of this question I'd like to set title, subject and, category. This part works fine, but at the end I need to set several document properties, but none of them are being set. I have a document containing several Heading 1 sections and I use a macro to extract a selected section (along with it's contents) and paste it to a new document. I'm having some trouble setting document properties using VBA in Word 2010.
0 Comments
Leave a Reply. |