Author Topic: Visio Shape UniqueID’s  (Read 122 times)

0 Members and 1 Guest are viewing this topic.

Visisthebest

  • Full Member
  • ***
  • Posts: 163
Visio Shape UniqueID’s
« on: September 24, 2020, 03:31:29 AM »
When I add a UniqueID GUID to a shape, I notice that when this shape is copied the copy has an empty-string UniqueID field (this is very desirable behavior).

My question is, will a new shape or a copied shape always have an empty-string UniqueIQ field or is there a setting in Visio that will generate a new UniqueID for a copied/created shape?

I am asking because if I can count on this behavior, then I can check if a shape has an empty-string UniqueID and know it has not been generated by our own code but created/copied by the user by hand. Very useful to know if this is always the case.

Paul Herber

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2947
    • Paul Herber's website
Re: Visio Shape UniqueID’s
« Reply #1 on: September 24, 2020, 07:28:21 AM »
The copied shape will always have a blank uniqueID. It cannot have the same ID as the original, as it would not then be unique!
Electronic and Electrical engineering, business and software stencils and applications for Visio -

https://www.paulherber.co.uk/

Visisthebest

  • Full Member
  • ***
  • Posts: 163
Re: Visio Shape UniqueID’s
« Reply #2 on: September 24, 2020, 08:05:56 AM »
Thank you Paul, but also not get a new UniqueID is what I wanted to be sure about! (unless this ID is added by our own code of course)