WorksharingDisplaySettings.SetGraphicOverrides
Description:
Sets the graphic overrides assigned to elements with a particular ownership status.
Sets the graphic overrides assigned to elements with a particular ownership status.
Overloads (4):
SetGraphicOverrides(CheckoutStatus,WorksharingDisplayGraphicSettings)
public void SetGraphicOverrides(
CheckoutStatus status,
WorksharingDisplayGraphicSettings overrides
)
-
statusThe ownership status of interest.
-
overridesThe desired graphic overrides for this ownership status.
public void SetWorksharingDisplaySettings(Document doc, WorksetId worksetId, String userName)
{
String message = String.Empty;
// get or create a WorksharingDisplaySettings current active document
WorksharingDisplaySettings displaySettings = WorksharingDisplaySettings.GetOrCreateWorksharingDisplaySettings(doc);
// set a new graphicSettings for CheckoutStatus - NotOwned
WorksharingDisplayGraphicSettings graphicSettings = new WorksharingDisplayGraphicSettings(true, new Color(255, 0, 0));
displaySettings.SetGraphicOverrides(CheckoutStatus.NotOwned, graphicSettings);
// set a new graphicSettings for ModelUpdatesStatus - CurrentWithCentral
graphicSettings = new WorksharingDisplayGraphicSettings(true, new Color(128, 128, 0));
displaySettings.SetGraphicOverrides(ModelUpdatesStatus.CurrentWithCentral, graphicSettings);
// set a new graphicSettings by a given userName
graphicSettings = new WorksharingDisplayGraphicSettings(true, new Color(0, 255, 0));
displaySettings.SetGraphicOverrides(userName, graphicSettings);
// set a new graphicSettings by a given workset Id
graphicSettings = new WorksharingDisplayGraphicSettings(true, new Color(0, 0, 255));
displaySettings.SetGraphicOverrides(worksetId, graphicSettings);
}
-
A non-optional argument was null
-
A value passed for an enumeration argument is not a member of that enumeration