none
Using VBA to get Custom Field Settings RRS feed

  • Question

  • Good Morning,

    I'd like to be able to check the settings of the user definable fields programmatically.

    The use case is that we upload our schedules to a well-known ERP application, which requires a large number of the MSP custom fields to be set aside for its own devious purposes. If a user adds a formula or a look-up, or changes the Calculation for Summary Rows setting, to any of these reserved fields, it breaks the link with the ERP system. So basically, I want to check the settings for each of these reserved fields programmatically, so that when a user reports an issue, we can quickly scan the schedule to see if this is a possible cause.

    I see we can get the formula with Application.CustomFieldGetFormula, and Application.CustomFieldGetName, but I'd also like to be able to check if a look-up has been applied, and the value of the value of "Calculation for task and group summary rows).

    Does anyone know how I could do this?

    Thanks,
    Andrew

    Thursday, May 31, 2012 9:22 AM

Answers

  • Andrew,

    You mentioned the word "devious" so remember, you set the stage. As far as I can tell from the object browser, there is no way to read the attributes or group summary setting for a custom field, however you can set those values.

    The first choice of cooperative exchange is of course training for all users. Make sure they are aware of the reserved custom fields and understand they are off limits. Once those ground rules are in place you can now run an audit macro that "sets" the values for the reserved fields, thereby clearing anything willfully or inadvertently set by a user.

    Not quite what you wanted, but perhaps the best you can do given the available options.

    John

    Thursday, May 31, 2012 3:13 PM

All replies

  • Forgot to say, I'm using Project Standard 2007 sp3 (i.e. no Project Server)
    Thursday, May 31, 2012 9:32 AM
  • Andrew,

    You mentioned the word "devious" so remember, you set the stage. As far as I can tell from the object browser, there is no way to read the attributes or group summary setting for a custom field, however you can set those values.

    The first choice of cooperative exchange is of course training for all users. Make sure they are aware of the reserved custom fields and understand they are off limits. Once those ground rules are in place you can now run an audit macro that "sets" the values for the reserved fields, thereby clearing anything willfully or inadvertently set by a user.

    Not quite what you wanted, but perhaps the best you can do given the available options.

    John

    Thursday, May 31, 2012 3:13 PM