I just got this error when doing Merge Replication on a SQL Server 2005 environment:
The error appeared when I tried to replicate a record inserted at the Publisher to the Subscriber. The Subscribers were built from backups, not snapshots. Apparently when you do that the NOT FOR REPLICATION flag is automatically set to No. In order for the Publisher->Subscriber scenario to work, that flag needs to be set to Yes.
You could manually do that for all tables with IDENTITY columns, or you could run this script.
That will set all NOT FOR REPLICATION flags to Yes and will print out the list of tables it looped through.
You may also get this error if the same flag is set to No for Triggers or other objects.
Hope this saves you some time