Discussion:
Writing files to SPS
(too old to reply)
John S
2005-10-26 14:35:14 UTC
Permalink
I have an app that currently writes an XML file to disk using a StreamWriter.
I now need to write this file into a SPS document library. StreamWriter won't
accept a URI for the file name.

Can someone suggest how this might be done.
Hollis D. Paul
2005-10-26 18:11:51 UTC
Permalink
Post by John S
I have an app that currently writes an XML file to disk using a StreamWriter.
I now need to write this file into a SPS document library. StreamWriter won't
accept a URI for the file name.
Can someone suggest how this might be done.
Take a look at the VBA code I use to attach a document to a message and mail it
to a "SharePoint enabled" public folder. You should be able to do something
similar.

My example of automatically capturing files for a SharePoint document
library is now posted on my blog. The document names and URLs are:

Automating Tip Capture with Office Systems 2003 – Part 1
http://msmvps.com/obts/articles/71691.aspx

Automating Tip Capture with Office Systems 2003 - Part 2
http://msmvps.com/obts/articles/71693.aspx


The process uses the mechanism of posting the documents as attachments
to Exchange public folders, and designating the target document
libraries as mail-enabled and linking them to a specific public folder.
Once this is done, a SharePoint process, related to the search timer,
looks in the public folder for new documents, and copies the
attachments to the document library.

Hollis D. Paul [MVP - Outlook]
***@outhousebythesound.com
Mukilteo, WA USA
Harsh[MSFT]
2005-10-26 22:10:03 UTC
Permalink
Hi Hollis,
Have you checked:
Get a handle to a doc library,
use this (SPList object) to create a new document and then write into this
file.

Let me know how this goes. In the mean while let me try and piece together a
sample on this.
--
Thanks and Regards
Harsh[MSFT]
Post by Hollis D. Paul
Post by John S
I have an app that currently writes an XML file to disk using a StreamWriter.
I now need to write this file into a SPS document library. StreamWriter won't
accept a URI for the file name.
Can someone suggest how this might be done.
Take a look at the VBA code I use to attach a document to a message and mail it
to a "SharePoint enabled" public folder. You should be able to do something
similar.
My example of automatically capturing files for a SharePoint document
Automating Tip Capture with Office Systems 2003 – Part 1
http://msmvps.com/obts/articles/71691.aspx
Automating Tip Capture with Office Systems 2003 - Part 2
http://msmvps.com/obts/articles/71693.aspx
The process uses the mechanism of posting the documents as attachments
to Exchange public folders, and designating the target document
libraries as mail-enabled and linking them to a specific public folder.
Once this is done, a SharePoint process, related to the search timer,
looks in the public folder for new documents, and copies the
attachments to the document library.
Hollis D. Paul [MVP - Outlook]
Mukilteo, WA USA
Hollis D. Paul
2005-10-27 04:32:47 UTC
Permalink
Post by Harsh[MSFT]
Get a handle to a doc library,
use this (SPList object) to create a new document and then write into this
file.
This is getting to sound like VB.Net, to which I haven't decided to move, but
probably will, or at least VSTO. I must say I have grown weary of changing
programming languages, just because MS needs a new Big Thing every 5 years to
motivate its own workers.

A sample would be a welcome addition to the mix. Let me know where it is
posted.

Hollis D. Paul [MVP - Outlook]
***@outhousebythesound.com
Mukilteo, WA USA
Wei-Dong XU [MSFT]
2005-10-31 02:13:26 UTC
Permalink
Hi ,

How are you? I am just checking if there is anything further we can do for
you. If so, please let me know.

Best Regards,
Wei-Dong XU
Microsoft Product Support Services
This posting is provided "AS IS" with no warranties, and confers no rights.
It is my pleasure to be of assistance.
John S
2005-10-31 07:51:05 UTC
Permalink
Hi,

I haven't tried either of the suggested methods yet but they look as if they
will point me in the right direction.

Thanks
Post by Wei-Dong XU [MSFT]
Hi ,
How are you? I am just checking if there is anything further we can do for
you. If so, please let me know.
Best Regards,
Wei-Dong XU
Microsoft Product Support Services
This posting is provided "AS IS" with no warranties, and confers no rights.
It is my pleasure to be of assistance
Wei-Dong XU [MSFT]
2005-10-31 09:14:04 UTC
Permalink
Please feel free to let me know if any further question on this matter. :-)

Best Regards,
Wei-Dong XU
Microsoft Product Support Services
This posting is provided "AS IS" with no warranties, and confers no rights.
It is my pleasure to be of assistance.

Loading...