How do I get CAML for a custom content type - sharepoint

I am trying to get the CAML for a custom content type that I am creating. What I am really doing is creating the content type in Visual Studio 2010 via CAML and then deploying that content type to my sandbox using the new deploy features in VS 2010. At that point, I am modifying the content type using the SharePoint interface (i.e changing advanced settings, adding columns, etc) since it is easy to do via the web interface. What I would like to do, is after I have made my changed, update my CAML in Visual Studio to match my changes.
I want to do this because I am creating custom fields and content types for my project and want to create a solution with these customizations. Since there doesn't seem to be a way to do this (create custom fields and content types) as a solution using SharePoint without putting them into a list, I am using Visual Studio and CAML for this. I also want to use Visual Studio and CAML so that I can put these CAML xml files in source control so that I can version my custom fields and custom types.
I have tried using tools like http://spcamlviewer.codeplex.com/ but that doesn't seem to work with SP 2010.
Does anyone have any suggestions? I wish Visual Studio would just have an update from SP button after I have deployed my solution and made changes on the server so it would sync VS from the SP server.

SharePoint Manager 2010

Related

Create Form Template from existing ones

Is there any way that I can create a template within forms to utilize for every user in the company?
For instance; let's say I have the Sales Order Screen (SO301000) and the Document Detail grid configured in certain way, that display different amount of columns than the default (either more or less columns).
For each user I want to use this template (and all the ones created) that I will apply when I add the new user.
I'l appreciate any guidance and help.
EDIT:
I provided answer for Form element ASP template below. Although reading your question again I think what you're trying to do would be more along the lines of automating grid column configuration. We call this feature Default Table Layout.
There's a feature request for it here:
https://feedback.acumatica.com/ideas/ACU-I-415
The feature has been shipped in version 2017R2 and is documented here:
https://help.acumatica.com/(W(1))/Main?ScreenId=ShowWiki&pageid=30f3229f-20f1-4055-9c03-e0fe3b37080d
Image copy of documentation page:
For ASP Form templates
There are two ways to work with customizations in Acumatica:
As a Customization Project, everything is done directly in Acumatica
instance through the web browser using the Customization Project Editor.
As an extension library (DLL file) compiled in Visual Studio which is then included in the FILES section of a Customization Project.
For method 1, I believe creating custom templates would be a bit of a hack and would not be officially supported, if someone knows otherwise please chime in.
For method 2, we ship the Visual Studio templates with the Acumatica Configuration Wizard (Acumatica ERP Installer).
Those templates are in the following folder:
My Documents\Visual Studio 20XX\Templates\ItemTemplates\Visual C#
The templates will be available for ASP.NET solution only. You can open Acumatica Instance Website as a solution if the website is already deployed:
When you open Add New Item dialog:
The Acumatica Templates will be available:
Those are standard Visual Studio templates so you can copy and re-use them to create your own. Microsoft documentation for creating user template applies and you can follow their guidelines. Note that working with Visual Studio and creating your own template is somewhat less user friendly than using Acumatica Customization Project Editor.
Acumatica T100 covers using Visual Studio to create customizations and would be a good starting point to learn the techniques involved:
https://openuni.acumatica.com/courses/development/t100-introduction-to-acumatica-framework/

How to add Custom Content Type Fields to Template in a SharePoint Add-In

I'm trying to recreate this functionality in a SharePoint add-in using Visual Studio 2015. I'm stuck at customizing the MS Word template to include metadata fields (DevNumber, DevOpen, etc). If I create a content type in SharePoint itself, I get a template that includes my fields as custom proprieties. How can I get similar functionality in a SharePoint add-in?
Run the app, then create a document using the default template.dotx. Update the document how you want the template to look, including adding property fields, then save the file as template.dotx in the appropriate folder - something like: https://myAppWeb/MyProjects/Lists/MyList/Forms

Create Biztalk 2013 artifact for sharepoint in visual studio

To create artifacts(schemas and ports) from WCF, webservice or database to be used in visual studio project, I right click the project and I choose Add Generated Items under the add menu and the related adapter generates them.
I have a case where I need to integrate data from sharepoint 2010 in my project. is there a way to generate these artifacts for a sharepoint list in my project?
As far as I know, you don't need to generate any schemas for SharePoint.
To populate a list for example you would need to fill in the properties of the SharePoint adapter by promoting an XML file as a property.
You can find more information here: http://jpsmit.bloggingabout.net/2013/01/24/biztalk-server-2013-sharepoint-adapter-walkthrough/

SharePoint 2010 - Creating a custom document library template

I'm trying to figure out if it is possible to create a custom document library template for SharePoint 2010. When a user clicks on the Libraries link on the quick launch menu of a new SharePoint site, and then clicks the Create button, the Create dialog is launched.
I know this dialog window hosts a Silverlight control, but obviously there is a way to create custom template types in this window. There is even a category that is called Blank & Custom. I've tried copying and modifying the DocumentLibrary feature located in the following location - C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\FEATURES, but that didn't seem to work.
Thanks for reading, I'm sure the answer is obvious but I've been stumbling over Google and MSDN all morning trying to figure this out but I haven't had any luck.
Well, unfortunately the answer is not that obvious. You'll have to create a new List Definition (a document library is actually a list). For that there are several ways, but as a developer, I guess the most common way is to do that through Visual Studio.
A basic tutorial that will guide you through the steps can be found here:
http://msdn.microsoft.com/en-us/library/ms466023.aspx
After you deploy your solution, a new list template (or document library, depending what you created) will show up in the dialog.
Yes, it is not that obvious at all.
Most of the Microsoft documentation is now based on using Visual Studio 2010 and are more focused on the lists than on the document libraries.
By the way, as told by Erwin, document libraries in SharePoint 2010 seems to have become lists, but the lack of documentation regarding the creation of custom lists remains anyway, so after having perform some successful trials I have decided to publish a step by step guide.
Sharepoint 2010 custom ducoment library

Cannot associate a custom SharePoint Workflow with a Content Type in SharePoint Server 2010

To preface, I am working with SharePoint Server 2010 Beta 2, Visual Studio 2010 Ultimate RC.
I have built a custom Content Type based on the Item type with a few custom site columns. I also have built a custom Sequential Workflow using Visual Studio 2010. This is a relatively simple workflow that creates a task, waits for the task to complete, sets the workflow to complete. I am able to deploy this workflow to the site collection through VS 2010 deploy (which is pretty nice, btw). The problem I have is that when I try to associate the custom Content Type with my custom workflow, that workflow is not listed in the workflow templates to choose from. There are only the OOTB SharePoint workflows to choose. The kicker is that if I create a list and associate a workflow to that list, my custom workflow is in the workflow template list. This makes sense since at the start of building a custom workflow in VS2010, one of the first questions is whether the workflow is a Site or a List workflow and I selected List. Is the issue that List workflows are not allowed to be associated with Content Types?!?
Thanks.
In your workflow's elements.xml, look for AssociationCategories and change it to ContentType like so:
<AssociationCategories>ContentType</AssociationCategories>
Big thanks to my co-worker, Yves for pointing this out :)

Resources