To Create Custom Field Item:
Display the New Project dialog box by pointing to New on the File menu, and then clicking New Project.
Expand the SharePoint node under either Visual C# or Visual Basic, and then click 2010.
Display the New Project dialog box by pointing to New on the File menu, and then clicking New Project.
Expand the SharePoint node under either Visual C# or Visual Basic, and then click 2010.
Click Empty SharePoint Project in the Templates pane, change the name of the project to CustomField1, and then click OK.
The SharePoint Customization Wizard appears. The Empty Project template is used for custom field items because there is no template for them.
- On the Specify the site and security level for debugging page, enter the URL for the SharePoint server site to which you want to add the new custom field item, or use the default location (http://<system name>/).
In the What is the trust level for this SharePoint solution? section, use the default value Deploy as a sandboxed solution.
Then Click Finish.
Add an Empty Element project item to the project. To do this, click the field's project node (CustomField1) in Solution Explorer and then click Add New Item on the Project menu.
- Expand the SharePoint node under either Visual C# or Visual Basic, and then click 2010.
- In the Templates pane, select Empty Element, keep the default name EmptyElement1, and then click Add.
- In the Elements.xml file under EmptyElement1, add the following after the <Elements> tag:
2..This adds a field that is named Patient Name.
At the top of the SharePoint Web page, click the Site Actions button and then click Site Settings.
Under the Galleries section of the Site Settings page, click the Site columns link. - Expand the SharePoint node under either Visual C# or Visual Basic, and then click 2010.
- In the Site Column Gallery page, scroll the page down to the Custom Columns heading and note the new field item added, Patient Name.
Close the browser.





No comments:
Post a Comment