Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

We have a multiple document libraries used in different projects in Sharepoint. Each document library in each project needs to have a unique naming convention for the files. For example. One of the library will use the naming convention as Cust1-Proj1-Dept1-Ver1.01.doc Another file in the same library will be like Cust2-Proj2-Dept3-Ver1.35.doc We want to force the users to upload the files to this particular library only in this naming convention. If someone uploads another file with just abc.doc as the file name, it should be rejected or display a warning message saying that, "for this particular document library please upload files in this format".

share|improve this question
add comment

1 Answer 1

You could code an event receiver catching the ItemAdding and make some logic to ensure the naming convention is respected. The, you could cancel the event and set the good error message to the user.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.