Hello Everyone,
I have designed an Infopath 2007 form which is not browser compatible. So my requirement is to allow users to attach some JPG or other small files and when they hit 'Save' button, all the attached files has to successfully stored into a Sharepoint list. So I have gone through this article http://support.microsoft.com/kb/892730 and successfully store all the attached files to my local drive by changing
myDecoder.SaveAttachment(@"<Path to save the file>") To myDecoder.SaveAttachment(@"c:\Files From Infopath")
//Get a reference to the attachment node.
IXMLDOMNode n = thisXDocument.DOM.selectSingleNode("my:myFields/my:theAttachmentField");
//Get the text of the node.
String theAttachment = n.text;
if(theAttachment.Length > 0)
{
InfoPathAttachmentEncoding.Decoder myDecoder = new InfoPathAttachmentEncoding.Decoder(theAttachment);
myDecoder.SaveAttachment(@"<Path to save the file>");
}
But how do I modify the code to store it into a list as an attachment or watever......
Can anyone direct me to proper code steps to store the attached files into a Sharepoint custom list.
Thanks,
Suhail