How to generate a STATIC unique identifier for each Excel row

 Blocked Profile -

How can generate a unique identifier for each Excel row that WILL NOT change when I delete or add rows?

3 replies

OK, here we go. Please understand, this solution will generate an error, specifically a "CIRCULAR CELL REFERENCE ERROR", but it does not change or alter the end result for locking the values.

Take a look at the image, it contains three seperate screen shots, each one after hitting F9 (recalculate). Notice the error at the bottom of the image, it was generated by the FIRST time the formula was triggered. This is a not so glam way of handling this.

Now, you could make a button to lock , and unlock the sheet, but only buttons will trigger it, as a formula cannot trigger a module!

It's kind of fun to do the impossible! -Walter Elias Disney
Thank you

A few words of thanks would be greatly appreciated. Add comment

CCM 2821 users have said thank you to us this month

Well, right off the head, this can be accomplished with a two step method. Stay with me.

A column that holds the UNIQUE number, along with another column that keeps track of whether or not the first colum has a vlaue in it, and upon a value being placed in the first column, does not recalculate. Try to imagine:

Column A hold boolean (y/n)
Column B hold unique value.
Column C holds the actual data.

If column A is set to N (default), which in this case means "NOT LOCKED", then a unique number is generated!

Once a value is set for C, then A should be changed to Y, and no other unique number will be generated in B, unless you manually set A to "N".

Just one VERY simple way of locking the values in!

It's kind of fun to do the impossible! -Walter Elias Disney
Registration date
Thursday October 5, 2017
Last seen
October 5, 2017

@ac3mark - I think this will work for the situation I am in as well. Would you mind giving an example of how to set this up (what would go in each column). Thanks!
Blocked Profile
Well, hang tight, its almost Friday, and I do my best posting on Friday!