http://www.infopathdev.com/forums/topic.asp?TOPIC_ID=263&SearchTerms=Current,user
That gives you all of the information you need. It works great, but you have to have C# in order to get it to work.
There is another solution on that same thread using an ActiveX component, but the hangup there is your document must be digitally signed in order ...