Solved

How to interpret Subject field when sending email to document library?

Posted on 2009-04-04
2
427 Views
Last Modified: 2012-05-06
Hi!

We are running a WSS site with several document libraries. When our users send emails to a certain document library in the subject field of the email they put the company name which becomes the destination folder in the library. So, if someone sending an email to the document library email address puts MYNEWCOMPANY in the subject line, such email with the attached files is placed by WSS under MYNEWCOMPANYNAME folder in the document library. If such folder doesn't exist, it is created automatically.

This library also contains a KEY field (column) which users then have to update manually in a spreadsheet mode directly on WSS page. This field is actually serving as a link between files. For example, to link documents and emails related to the same order or RFQ. Is there a way to automate this procedure so that users will add for example '/' between company name and description of the KEY in the email subject so that in the WSS this KEY description will be automatically copied to KEY filed so that they will not have to open document library and manually insert this descriptions each time after sending an email to a document library? Or there might be some better workaround to this problem?

For example, the library contains the following columns:

Type, Name, ModifiedBy, Document Type, KEY

When user will place in subject the string like 'CompanyName / Keytxt ' sharepoint will place the email with all the attached files into 'CompanyName' folder and 'Keytxt' in KEY column?
0
Comment
Question by:Zaurb
2 Comments
 
LVL 11

Accepted Solution

by:
CraigYellick earned 500 total points
ID: 24068026
This is really a SharePoint question and isn't something that can be solved on the SQL Server side of things.  SharePoint document libraries have an API with an event model. You can write a document library "listener" that reacts to events in a document's life cycle, from initial creation to changes to delete. In your case you'd listen for new documents being added to the library and then make whatever changes you desire to the new document. This includes renaming, adjusting properties and moving it between folders or even entirely different libraries.

Instead of creating folders I recommend putting all documents in a single root folder and using document properties (aka metadata) and views to provide different ways to filter and organize the documents. When you create folders you make it a lot more difficult to find and manage documents.

Here are some links to examples for adding event-handling code to document libraries:

http://msdn.microsoft.com/en-us/library/ms462433.aspx
http://weblog.vb-tech.com/nick/archive/2006/07/31/1706.aspx
0
 
LVL 1

Author Comment

by:Zaurb
ID: 24086908
I've also found that it is possible to use "SPEmailEventReceiver" Class (http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.spemaileventreceiver.aspx) for parsing emails in SP workflow. However, I have used SPD2007 for a couple of month now, but I have no idea on how to use Visual Studio to write customized things for SharePoint. Any help, links, walkthroughs on configuring Visual Studio for using with WSS are most welcome!

0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

Having an SQL database can be a big investment for a small company. Hardware, setup and of course, the price of software all add up to a big bill that some companies may not be able to absorb.  Luckily, there is a free version SQL Express, but does …
These days socially coordinated efforts have turned into a critical requirement for enterprises.
Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now