AnsweredAssumed Answered

What is vCustPropNames?

Question asked by Keaton Warn on Jun 12, 2018
Latest reply on Jun 12, 2018 by Ivana Kolin

I am having some issues with vCustPropNames in an array. For some reason it works in some code and not others. However, the main issue right now has to do


For example, it works fine in the "Find Revision Letter" macro I have attached. It is a modified macro originally written by Keith Rice that exports the custom properties to an Excel spreadsheet. I modified it to find a specific custom property (the Revision custom property present in the company's drawing files) and print it in the Immediate box (ctrl+g).


I am trying to use a variation of the Find Revision Letter code to extract the revision letter in another macro, attached as Pack and Go Experimental.

However, the compiler gives me a

          "Compiler error: Variable not defined"

message if I forget to define "strRevision" as a string in the header.

If I declare it as a string, I get a

          "Run-time error '91': Object variable or With block variable not set"

message from the Set swCustPropMgr = swModel.Extension.CustomPropertyManager("") line. This is weird because this line is before the offending strRevision line. Shouldn't this line error out before the strRevision line, regardless of if the strRevision is decalred or not?


If I remove the Set swCustomPropMgr = swModel.Extension.CustomPropertyManager("") line, I get array errors in the ReDim lines and tend to have a lot of issues with vCustPropNames.