Hey,
You can perform that task within an InfoPath form itself. The form will need to be fully trusted.
VB Script Code snippet below:
'Purpose to clear the form cache on the client machine
'date 04/22/2006
'misc "C:\Program Files\Microsoft Office\OFFICE11\INFOPATH.EXE" /cache clearall
Dim wshShell
Dim sRun, sParam, sMsg
sParam = "C:\Program Files\Microsoft Office\OFFICE11\INFOPATH.EXE /cache clearall"
Set wshShell = Createobject("WScript.Shell")
wshShell.Exec sParam
Set wshShell = Nothing
This will clear all forms in the cache except for the form that is running the code.
Hope it helps!
Mary