开发者

Sharepoint 2010 How to index a folder in a content database?

开发者 https://www.devze.com 2023-04-03 11:00 出处:网络
I have to create a proof of concept to test SharePoint 2010.We are two developments groups that will merge documentation into the same CMS.

I have to create a proof of concept to test SharePoint 2010. We are two developments groups that will merge documentation into the same CMS.

The problem is that the other group used SharePoint from the starts and us were using a network drive.

The goal is to have our documentation imported into Sharepoint, but with a different search page. We don't开发者_JAVA技巧 want to search into the documentation of the other group and same thing for them.

I'm really stuck here.

I created a new content database named : WSS_Content_two.

WSS_Content could be used by the other group and WSS_Content_two for us.

Does I make sens at this point ?

My Question :

How can I import all the documents from t:\documentation into Sharepoint and search with a web page ?

I have also SharePoint Designer 2010, if I need it.

I found that I could add a new datasource content (sorry the link is in french): Administration centrale Application de service de recherche : Modification de la source de contenu

but I wasn't able to index my network drive :

in the section : start URL (don't have the name in english) \myserver\Documentation-test (which Documentation-test, is a localfolder like d:\documentation-test)

I tried :

\myserver\mymapnetworkdrive and it didn't works.


I will probably write a small document migrartion tool to migrate all of your document into sharepoint. see example below

byte[] bytes = new byte[Convert.ToInt32 (("Result from your File read").Lenght)];
                using (SPSite objSite = new SPSite(“YourSiteUrl"))
                {
                    using (SPWeb objWeb = objSite.OpenWeb())
                    {
                        SPFolder dLibrary = objWeb.Folders["Name of Document Library"];              
                        objWeb.AllowUnsafeUpdates = true;
                        dLibrary.Files.Add("Document Name","Document Source", bytes);                    
                    }
0

精彩评论

暂无评论...
验证码 换一张
取 消