Is this form a SharePoint list form? Or a regular InfoPath form with a data connection to a SharePoint list?
I would probably have a hidden field that I'd use for this (I usually put fields like this in a secondary data source) and leverage that. I'm attaching a simple sample. Save it locally, right click and select design. From there you can preview it and give it a try.