Yesterday, I was working on a SharePoint Workflow. I needed to copy the final InfoPath (xml) to a different library. My first thought was to use the spfile.copyto but that gave me the “Value does not fall within the expected range.” or COM errors.
Instead of wasting my time trying to figure out how to make the copyto  method copy across site collections, I did the following.

SPFile file = workflowProperties.Item.File;
string xmlFileContent = System.Text.Encoding.Default.GetString(file.OpenBinary());
int index = xmlFileContent.IndexOf(”<?xml”);
if (index != 0)
    xmlFileContent = xmlFileContent.Remove(0, index);
XmlDocument doc = new XmlDocument();
XmlNamespaceManager mgr = new XmlNamespaceManager(doc.NameTable);
mgr.AddNamespace(”my”, @””

 I needed to set the status before I move to the new location.

XmlNode nodeStatus = doc.DocumentElement.SelectSingleNode(“/my:myFields/my:FormStatus”, mgr);
nodeStatus.InnerText = status;
char[] newFile = doc.InnerXml.ToCharArray();
Stream s = file2.OpenBinaryStream();
SPFolder target = curweb.GetFolder(“Contract”);
SPFile ofile = curweb.GetFile(“Contract/” + _requestName + “.xml”);
if (ofile.Exists)
target.Files.Add(_requestName + “.xml”, s);
fileURLWorkSpace = thedestinationlocation-URL + _requestName + “.xml”;

 Hope this helps someone.