*** NEVERMIND...I FOUND THE PROBLEM. *** I was ignoring one simple line of code.
I am attempting to programmatically add an attachment to a SharePoint list using the Lists Web services API. Here is the algorithm I am following:
1) Created list item using CAML. The item ID is returned.
2) Using the returned item ID from #1, call the "AddAttachment" method to add an attachment.
3) Receive "401: Unauthorized" error.
I tried adding the same attachment to list manually using the same credentials and it works. What am I missing? Is it a problem with the file upload? Is it a problem with the list item not being in edit mode? Can someone please help? Thanks in advance!
-B