简体   繁体   中英

Create .NET assembly connector programmatically in SharePoint 2010

Does anybody know how to create a .NET assembly connector programmatically? I mean I want to generate an .NET assembly in runtime using Reflection.Emit and deploy it to SharePoint.

I've found this great post:

http://www.toddbaginski.com/blog/archive/2009/12/01/how-to-programmatically-create-a-sharepoint-2010-external-content-type.aspx

where a database external type is created, but I need to create an external type based on a .NET assembly

Thanks

This is not really an answer to your question, but just an observation/suggestion. In order to deploy an assembly that SharePoint will use you have to get it in the GAC. I would think if you created some code to Emit the assembly then had either your current app or another app create a PowerShell script to add the assembly to the GAC and wire up all the SharePoint STSADM stuff, then you could accomplish what you want. I may have better ideas with more details of where you are generating the new assembly (from some external app, etc). Hope this helps or at least sparks some ideas.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM