I haven’t really worked with workflow in a document library with versioning turned on yet…until now.
What we found is that each time some metadata of the document was changed using workflowProperties.Item.Update, a new version of the of the file was created!
You could argue that this is OK and for the majority of implementations this would probably be fine however we needed to find a way around it:
If you do not want to re-version the document when a workflow changes the metadata then you can use the workflowProperties.Item.SystemUpdate method, see the details here –
The SystemUpdate method writes the data directly to the database and also accepts a boolean flag defining whether or not to increment the version number, perfect!
Hope this helps!