id stringlengths 14 16 | text stringlengths 2 3.14k | source stringlengths 45 175 |
|---|---|---|
0d53c7353ee0-4 | // Defines the name of the managed property 'Author'
private const string AuthorProperty = "Author";
// Defines the temporary directory where binary data will be stored.
private const string TempDirectory = @"C:\\Temp";
// Defines the error code for managed properties with an unexpected type.
private const int Unexpe... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-use-the-content-enrichment-web-service-callout-for-sharepoint-server |
0d53c7353ee0-5 | private readonly ProcessedItem processedItemHolder = new ProcessedItem
{
ItemProperties = new List<AbstractProperty>()
};
Add the following code for the ProcessItem method.
public ProcessedItem ProcessItem(Item item)
{
processedItemHolder.ErrorCode = 0;
processedItemHolder.ItemProperties.Clear();
t... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-use-the-content-enrichment-web-service-callout-for-sharepoint-server |
0d53c7353ee0-6 | {
var outputFile = File.Create(fullFilePath);
using (var writer = new BinaryWriter(outputFile))
{
writer.Write(item.RawData);
}
}
}
}
}
}
catch (Exception)
{
processedIte... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-use-the-content-enrichment-web-service-callout-for-sharepoint-server |
0d53c7353ee0-7 | Set-SPEnterpriseSearchContentEnrichmentConfiguration -SearchApplication
$ssa -ContentEnrichmentConfiguration $config
The sequence of Windows PowerShell cmdlets help you to first create a configuration object by using the New-SPEnterpriseSearchContentEnrichmentConfiguration cmdlet. The configuration object is then... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-use-the-content-enrichment-web-service-callout-for-sharepoint-server |
43f9324f5a64-0 | Word breaking is one of the key Natural Language Processing (NLP) features that enable search and improve search results (or recall). Word breakers split a stream of text into individual words or tokens on which you can base additional language processing. Word breakers are language-specific. In addition to built-in wo... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/custom-word-breakers-in-sharepoint-server |
43f9324f5a64-1 | In the right pane, open the shortcut menu for the WBDLLPathOverride registry value, and then choose Modify .
In the Edit String dialog box, in the Value data box, type the path to your custom word breaker DLL, and then choose OK . The new DLL should be located in the same path as the existing DLL that is be... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/custom-word-breakers-in-sharepoint-server |
43f9324f5a64-2 | Spanish (Modern Sort)
Swedish
Tamil
Telugu
Thai
Ukrainian
Urdu
Vietnamese
See also
Configure search in SharePoint
Implementing a Word Breaker
IWordBreaker interface | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/custom-word-breakers-in-sharepoint-server |
ddc9a1229f82-0 | Learn how to configure item level security when crawling external data with BCS indexing connectors in SharePoint.
External systems with NTLM authentication
For external systems that support NTLM authentication, the security descriptor can be obtained for each instance of the external content type at crawl time... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-configure-item-level-security-in-sharepoint |
ddc9a1229f82-1 | </Parameter>
<Parameter Direction="Return" Name="BaseItemsRead Item">
<TypeDescriptor TypeName="System.Data.IDataReader, System.Data, Version=2.0.0.0,
Culture=neutral, PublicKeyToken=b77a5c561934e089" IsCollection="true" Name="BaseItemsRead Item">
<TypeDescriptors>
<TypeDescriptor TypeName=... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-configure-item-level-security-in-sharepoint |
ddc9a1229f82-2 | </MethodInstances>
</Method>
Note
ems are limited to a specific size, which access control lists (ACL) can easily exceed. Therefore, the Search connector framework ignores requests to cache items if they contain a security descriptor field.
External content type method
If you have a method defined in t... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-configure-item-level-security-in-sharepoint |
ddc9a1229f82-3 | <MethodInstance Name="GetItemSecurity_Instance" Type="BinarySecurityDescriptorAccessor"
ReturnParameterName="Return" ReturnTypeDescriptorName="SecurityDescriptor"
ReturnTypeDescriptorLevel="0">
<Properties>
<Property Name="WindowsSecurityDescriptorField" Type="System.String">
SecurityDescrip... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-configure-item-level-security-in-sharepoint |
ddc9a1229f82-4 | }
External systems with authentication schemes that can be mapped to NTLM authentication
If the external system does not support NTLM authentication, but the external system users can be mapped to Windows users by using a mapping table, you can use the approach described in the previous two code examples to pr... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-configure-item-level-security-in-sharepoint |
ddc9a1229f82-5 | return secDes;
}
See also
Search connector framework in SharePoint
Implementing a BinarySecurityDescriptorAccessor
Enhancing the BDC model file for Search in SharePoint | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-configure-item-level-security-in-sharepoint |
5f469c0c08a1-0 | Learn how to modify the BDC model file for a database BCS indexing connector to enable the Search in SharePoint crawler to crawl binary large object (BLOB) data stored in a SQL Server database.
Crawling BLOB data
The Business Data Connectivity (BDC) service supports reading BLOB data types, which is useful for stre... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-crawl-binary-large-objects-blobs-in-sharepoint |
5f469c0c08a1-1 | 2
File2
.doc
0xD…
application/msword
3
File3
.txt
OxE…
text/plain
Modifying the BDC model file to enable crawling of BLOB data
After you confirm that the database table contains the extension or MIME type information for the BLOB data, you can use Microsoft SharePoint Designer to create ... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-crawl-binary-large-objects-blobs-in-sharepoint |
5f469c0c08a1-2 | Create a new method that returns the BLOB field. You should define a StreamAccessor type method instance for this method, as shown in the following example.
Note
The table name in this example is Attachment.
<Method Name="GetData">
<Properties>
<Property Name="RdbCommandText" Type="System.String">SELE... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-crawl-binary-large-objects-blobs-in-sharepoint |
5f469c0c08a1-3 | Version=2.0.3600.0,
Culture=neutral,
PublicKeyToken=b77a5c561934e089" Name="Data" />
</TypeDescriptors>
</TypeDescriptor>
</TypeDescriptors>
</TypeDescriptor>
</Parameter>
</Parameters>
<MethodInstances>
<MethodInstance Name="DataAccesso... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-crawl-binary-large-objects-blobs-in-sharepoint |
a0c78f207044-0 | Learn how to use the search specific properties in the Business Data Connectivity (BDC) service metadata model for crawling associations, and the different user experiences that you can enable.
Crawling the associated external content type
Microsoft Business Connectivity Services (BCS) enables you to link two r... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-crawl-associated-external-content-types-in-sharepoint |
a0c78f207044-1 | Incremental crawl effects from external content type associations
Child external items are re-crawled and updated for timestamp-based incremental crawls if the timestamp of the child external item changes.
For attachment external content types, the timestamp of the parent external item is interpreted as the timesta... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-crawl-associated-external-content-types-in-sharepoint |
a0c78f207044-2 | <Properties>
<Property Name="DirectoryLink" Type="System.String">x</Property>
</Properties>
<SourceEntity Namespace="ParentExternalContentType" Name="Parent" />
<DestinationEntity Namespace="ChildExternalContentType" Name="Child External Content Type" />
</Association>
Note
You can specify an... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-crawl-associated-external-content-types-in-sharepoint |
e012f35122ad-0 | Learn about the properties in the BDC metadata model that are applicable to BCS indexing connectors which enable Search in SharePoint to crawl external data.
Search properties for BDC model files
The connector framework in Search enables you to crawl external data, making it available in search results through ... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/enhancing-the-bdc-model-file-for-search-in-sharepoint |
e012f35122ad-1 | OutputUriProcessor
LobSystem
Specifies the name of the class that processes the output URL before passing it to the search system from the connector. Applies to .NET and custom BCS indexing connectors. For more information, see Creating a Custom Indexing Connector .
SystemUtilityTypeName
LobSystem... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/enhancing-the-bdc-model-file-for-search-in-sharepoint |
e012f35122ad-2 | DisplayUriField
Method
Specifies the URL to display in search results. If specified, this property overrides the profile page URL provided by BCS. If not specified, the URL displayed in search results starts with bdc3:// , and is not understood by the browser.
LastModifiedTimeStampField
Method
S... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/enhancing-the-bdc-model-file-for-search-in-sharepoint |
e012f35122ad-3 | Contains the start time of the last crawl.
SynchronizationCookie
FilterDescriptor
Specifies that the external content source returns a cookie after a crawl, which is then resent by the indexing connector during the next enumeration call. The external content source uses the cookie to determine what has ... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/enhancing-the-bdc-model-file-for-search-in-sharepoint |
e012f35122ad-4 | Enumeration optimization when crawling external systems
Do not enumerate more than 100,000 items per call to the external system. Long-running enumerations can cause intermittent interruptions and prevent a crawl from completing. We recommend that your BDC model structures the data into logical folders that can be en... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/enhancing-the-bdc-model-file-for-search-in-sharepoint |
e012f35122ad-5 | Security in BDC model files
If the repository uses NTLM authentication, we recommend that you specify PassThrough authentication for crawling.
Profile pages may require that you use the Secure Store Service because of the multi-hop delegation problem from the front-end web server. If you encounter this problem,... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/enhancing-the-bdc-model-file-for-search-in-sharepoint |
173957902d06-0 | Learn about the new features available for developers in Search in SharePoint.
Search client object model for access to Query object model functionality for online, on-premises, and mobile development
SharePoint Search includes a client object model (CSOM) that enables access to most of the Query object model f... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/what-s-new-in-sharepoint-search-for-developers |
173957902d06-1 | SQL Syntax Support Removed
Custom search solutions in SharePoint do not support SQL syntax . Search in SharePoint supports FQL syntax and KQL syntax for custom search solutions. You cannot use SQL syntax in custom search solutions using any technologies, including the Query server object model, the client objec... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/what-s-new-in-sharepoint-search-for-developers |
173957902d06-2 | http://server/_api/$metadata
For general information about the REST service in SharePoint, see Use OData query operations in SharePoint REST requests .
SharePoint Search Query web service is deprecated
The Query web service (located in the path http://server/site/_vti_bin/search.asmx ) is deprecated in Sh... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/what-s-new-in-sharepoint-search-for-developers |
173957902d06-3 | You can specify any property in the property bag, including user-defined properties, as query rule conditions. You use query rules to customize the search experience for the kinds of queries that are important to your users. When a query meets conditions specified in a query rule, the rule specifies actions to improve ... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/what-s-new-in-sharepoint-search-for-developers |
173957902d06-4 | New ONEAR operator
The ONEAR operator provides ordered near functionality. It receives an optional parameter that indicates maximum token distance; the default value is 8 .
The ONEAR operator preserves the order of the input expressions. For unordered proximity, use NEAR .
You can use the ONEAR operator i... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/what-s-new-in-sharepoint-search-for-developers |
173957902d06-5 | Rich results framework for customizing search results UI
SharePoint Search includes a new results framework that makes it easy to customize the appearance (look and feel) of the search results user interface (UI). Now, instead of writing a custom XSLT to change how search results are displayed, you can customize ... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/what-s-new-in-sharepoint-search-for-developers |
173957902d06-6 | Configure search in SharePoint
Building search queries in SharePoint
How to: Use a custom security trimmer for SharePoint Server search results | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/what-s-new-in-sharepoint-search-for-developers |
cb78de877ed9-0 | Learn how to customize the SharePoint Geolocation field type programmatically using client-side rendering.
SharePoint introduces a new field type named Geolocation that enables you to annotate SharePoint lists with location information. In columns of type Geolocation, you can enter location information as a pair of l... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-extend-the-geolocation-field-type-using-client-side-rendering |
cb78de877ed9-1 | Microsoft Visual Studio 2012
Office Developer Tools for Visual Studio 2012
Access to a SharePoint list, with sufficient privileges to add a column
Core concepts to know for customizing the Geolocation field
Table 1. Core concepts for extending the Geolocation field type
Article title
Description
... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-extend-the-geolocation-field-type-using-client-side-rendering |
cb78de877ed9-2 | In Solution Explorer , open the shortcut menu for the project name (in our example, it is CustomGeolocationField ), and choose Add , New Item .
In the Add New Item dialog box, under the Code templates, choose Class , and specify the name for the class ( CustomGeolocationField.cs in this example).
In ... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-extend-the-geolocation-field-type-using-client-side-rendering |
cb78de877ed9-3 | Step 2: Create a custom field class
A field class is a class whose instances can represent particular fields that are based on your custom field type. This class must inherit from SPField or one of the classes in SharePoint Foundation that derive from it. To enable you to extend or customize the Geolocation field t... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-extend-the-geolocation-field-type-using-client-side-rendering |
cb78de877ed9-4 | /// <summary>
/// Create an instance of CustomGeolocationField object.
/// </summary>
/// <param name="fields">Field collection</param>
/// <param name="typeName">type name of the field</param>
/// <param name="displayName">display name of the field</param>
public CustomGeolocationField(SPField... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-extend-the-geolocation-field-type-using-client-side-rendering |
cb78de877ed9-5 | public override object GetFieldValue(string value)
{
return base.GetFieldValue(value);
}
Add the following override of the GetValidatedString method to the CustomGeolocationField class:
/// <summary>
/// get validated string
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
public... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-extend-the-geolocation-field-type-using-client-side-rendering |
cb78de877ed9-6 | 'CustomGeolocationField': {
'View': CustomGeolocationFieldTemplate.RenderGeolocationField,
'DisplayForm': CustomGeolocationFieldTemplate.SPFieldGeolocation_Display,
'EditForm': CustomGeolocationFieldTemplate.SPFieldGeolocation_Edit,
'NewForm': CustomGeolocationFieldTempla... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-extend-the-geolocation-field-type-using-client-side-rendering |
cb78de877ed9-7 | if (fldvalue != null) {
_latitude = fldvalue.latitude;
_longitude = fldvalue.longitude;
}
var result = '<div>';
result += '<span>Latitude:</span><span>' + _latitude + '</span><span>Longitude:</span><span>' + _longitude + '</span>';... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-extend-the-geolocation-field-type-using-client-side-rendering |
cb78de877ed9-8 | if (_myData == null || _myData.fieldSchema == null)
return '';
var _latitude = null;
var _longitude = null;
var _inputId_Latitude = _myData.fieldName + '_' + _myData.fieldSchema.Id + '_$geolocationField_Latitude';
var _inputId_Longitude... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-extend-the-geolocation-field-type-using-client-side-rendering |
cb78de877ed9-9 | // Set the initial values.
if ((_latitudeBox != null && _longitudeBox != null) &&
(_latitude != null && _longitude != null)) {
_latitudeBox.value = _latitude;
_longitudeBox.value = _longitude;
... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-extend-the-geolocation-field-type-using-client-side-rendering |
cb78de877ed9-10 | },
RenderGeolocationField: function (inCtx, field, listItem, listSchema) {
var fldvalue = CustomGeolocationFieldTemplate.ParseGeolocationValue(listItem[field.Name]);
var result = '';
if (fldvalue != null) {
var result = '<div>';
... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-extend-the-geolocation-field-type-using-client-side-rendering |
cb78de877ed9-11 | 'CustomGeolocationField': {
'View': CustomGeolocationFieldTemplate.RenderGeolocationField,
'DisplayForm': CustomGeolocationFieldTemplate.SPFieldGeolocation_Display,
'EditForm': CustomGeolocationFieldTemplate.SPFieldGeolocation_Edit,
'NewForm': CustomGeoloc... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-extend-the-geolocation-field-type-using-client-side-rendering |
cb78de877ed9-12 | <Field Name="TypeDisplayName">Custom Geolocation field</Field>
<Field Name="TypeShortDescription"> Custom Geolocation field </Field>
<Field Name="UserCreatable">TRUE</Field>
<Field Name="ShowOnListCreate">TRUE</Field>
<Field Name="ShowOnSurveyCreate">TRUE</Field>
<Field Name="ShowOnDocumentLibraryCr... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-extend-the-geolocation-field-type-using-client-side-rendering |
cb78de877ed9-13 | Choose the F5 key.
Note
When you choose F5, Visual Studio builds the solution, deploys the solution, and opens the SharePoint website where the solution is deployed.
Create a custom list and add a new Custom Geolocation field column.
Add one item to the list, and provide Longitude and Latitude values ... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-extend-the-geolocation-field-type-using-client-side-rendering |
9c1aaf8cefa8-0 | Learn how to set the Bing Maps key programmatically at the web (SharePoint Server and SharePoint Online) and farm(SharePoint Server) level by using the SharePoint client object model and Windows PowerShell, to enable the Bing Maps functionality in SharePoint lists and location-based web and mobile apps.
Prerequisites... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-set-the-bing-maps-key-at-the-web-and-farm-level-in-sharepoint |
9c1aaf8cefa8-1 | To set the Bing Maps key at the farm level using Windows PowerShell
Log on to the SharePoint server as an administrator, and open the SharePoint Management Shell.
Execute the following command:
Set-SPBingMapsKey -BingKey "<Enter a valid Bing Maps key>"
The Bing Maps key is now set at the farm level in Share... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-set-the-bing-maps-key-at-the-web-and-farm-level-in-sharepoint |
9c1aaf8cefa8-2 | In the New Project dialog box, choose C# in the Installed Templates box, and then choose the Console Application template.
Give the project a name, and then choose the OK button.
Visual Studio creates the project. Add a reference to the following assemblies, and choose OK .
Microsoft.SharePoi... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-set-the-bing-maps-key-at-the-web-and-farm-level-in-sharepoint |
9c1aaf8cefa8-3 | ClientContext context = new ClientContext("<Site Url>");
Web web = context.Web;
web.AllProperties["BING_MAPS_KEY"] = "<Valid Bing Maps Key>"
web.Update();
context.ExecuteQuery();
}
}
Replace the <Site Url>; and <Valid Bing Maps Key> with valid values.... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-set-the-bing-maps-key-at-the-web-and-farm-level-in-sharepoint |
e3cfb234e8bd-0 | Learn how to display location information by using a map view in SharePoint lists. You can create a map view manually via the SharePoint user interface (UI) or programmatically by using the new Geolocation field type.
SharePoint introduces a new field type named Geolocation that enables you to annotate SharePoint... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/create-a-map-view-for-the-geolocation-field-in-sharepoint |
e3cfb234e8bd-1 | An MSI package named SQLSysClrTypes.msi must be installed on every SharePoint front-end web server to view the Geolocation field value or data in a list. This package installs components that implement the new geometry, geography, and hierarchy ID types in SQL Server 2008. By default, this file is installed for Share... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/create-a-map-view-for-the-geolocation-field-in-sharepoint |
e3cfb234e8bd-2 | What is a map view?
A map view is a SharePoint view that displays a map (with data obtained from the Bing Maps service), using longitude and latitude entries from the Geolocation field type. When the Geolocation field type is available on the SharePoint list, a map view can be created either programmatically or f... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/create-a-map-view-for-the-geolocation-field-in-sharepoint |
e3cfb234e8bd-3 | Figure 3. Choosing fields for a map view
Note
At least one Geolocation field is required to create a map view. You cannot select multiple Geolocation fields for a map view, although you can create two different map views that use two different Geolocation fields.
After you add the required Geolocatio... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/create-a-map-view-for-the-geolocation-field-in-sharepoint |
e3cfb234e8bd-4 | CreateMapView ();
Console.WriteLine("A map view is created successfully");
}
private static void CreateMapView()
{
// Replace <Site URL> and <List Title> with valid values.
ClientContext context = new ClientContext("<Site Url>");
List oList = context.Web.Lists.GetByTitle("<List Title>");
ViewC... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/create-a-map-view-for-the-geolocation-field-in-sharepoint |
e3cfb234e8bd-5 | Blue When a user hovers over a list item, the pushpin color changes from orange to blue. Both the pushpin in the left pane and the matching pushpin on the map change color
Figure 5. A map view with different pushpin colors
After you create a map view, all items appear as pushpins. The user can get more informa... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/create-a-map-view-for-the-geolocation-field-in-sharepoint |
517cd25f637a-0 | Learn how to programmatically add a Geolocation column to a list in SharePoint. Integrate location information and maps in SharePoint lists and location-based websites by using the new Geolocation field creating your own Geolocation-based field type.
SharePoint introduces a new field type named Geolocation that enabl... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-add-a-geolocation-column-to-a-list-programmatically-in-sharepoint |
517cd25f637a-1 | Important
Please note that you are responsible for compliance with terms and conditions applicable to your use of the Bing Maps key, and any necessary disclosures to users of your application regarding data passed to the Bing Maps service.
Visual Studio 2010
SharePoint Online Management Shell: https://www.... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-add-a-geolocation-column-to-a-list-programmatically-in-sharepoint |
517cd25f637a-2 | Start Visual Studio.
On the menu bar, choose File, New Project . The New Project dialog box opens.
In the New Project dialog box, choose C# in the Installed Templates box, and then choose the Console Application template.
Give the project a name, and then choose the OK button.
Visual Studio... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-add-a-geolocation-column-to-a-list-programmatically-in-sharepoint |
517cd25f637a-3 | Navigate to the list. You should be able to see a column named Location of type Geolocation in the list. You can now enter some values and see it in action. Figure 1 shows the default location and map features that you can expect to see in your list.
Figure 1. Summarized view of the default location and map feature... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-add-a-geolocation-column-to-a-list-programmatically-in-sharepoint |
517cd25f637a-4 | ListItemCreationInformation itemCreationInfo = new ListItemCreationInformation();
ListItem oListItem = oList.AddItem(itemCreationInfo);
oListItem["Title"] = "New Title";
FieldGeolocationValue oGeolocationValue = new FieldGeolocationValue();
oGeolocationValue.Latitude = (double)17.4;
oGeolocationValue.Longit... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-add-a-geolocation-column-to-a-list-programmatically-in-sharepoint |
ca4423ba20d8-0 | Learn how to create, retrieve, and change SharePoint user profiles and user profile properties programmatically by using the SharePoint server object model.
What are user profiles in SharePoint?
In SharePoint, user profiles represent SharePoint users. User profile properties represent information about the users an... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-work-with-user-profiles-and-organization-profiles-by-using-the-server-obj |
ca4423ba20d8-1 | Note: Make sure the Prefer 32-bit setting is not selected in the project's Build properties.
Add references to the following assemblies:
Microsoft.Office.Server
Microsoft.Office.Server.UserProfiles
Microsoft.SharePoint
System.Web
Replace the contents of the Program class with the code exam... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-work-with-user-profiles-and-organization-profiles-by-using-the-server-obj |
ca4423ba20d8-2 | using Microsoft.Office.Server.UserProfiles;
using Microsoft.SharePoint;
using System.Web;
namespace UserProfilesSSOM
{
class Program
{
static void Main(string[] args)
{ | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-work-with-user-profiles-and-organization-profiles-by-using-the-server-obj |
ca4423ba20d8-3 | // Replace "domain\\username" and "servername" with actual values.
string newAccountName = "domain\\username";
using (SPSite site = new SPSite("http://servername"))
{
SPServiceContext serviceContext = SPServiceContext.GetContext(site);
try
... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-work-with-user-profiles-and-organization-profiles-by-using-the-server-obj |
ca4423ba20d8-4 | catch (System.Exception e)
{
Console.WriteLine(e.GetType().ToString() + ": " + e.Message);
Console.Read();
}
}
}
}
}
Code example: Create user profile properties by using the SharePoint server object model
User prof... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-work-with-user-profiles-and-organization-profiles-by-using-the-server-obj |
ca4423ba20d8-5 | // Create a URL property.
CoreProperty coreProp = corePropMgr.Create(false);
coreProp.Name = "AppsWebsite";
coreProp.DisplayName = "Apps site";
coreProp.Type = PropertyDataType.URL;
coreProp.Length = 100;
... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-work-with-user-profiles-and-organization-profiles-by-using-the-server-obj |
ca4423ba20d8-6 | Console.WriteLine("The properties were created.");
Console.Read();
}
catch (System.Exception e)
{
Console.WriteLine(e.GetType().ToString() + ": " + e.Message);
Console.Read();
}
}
... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-work-with-user-profiles-and-organization-profiles-by-using-the-server-obj |
ca4423ba20d8-7 | // Retrieve a specific user profile. Change the value of a user profile property
// and save (commit) the change on the server.
UserProfile user = userProfileMgr.GetUserProfile(targetAccountName);
Console.WriteLine("\\nRetrieving user profile for " + user.Disp... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-work-with-user-profiles-and-organization-profiles-by-using-the-server-obj |
ca4423ba20d8-8 | // Replace "servername" with an actual value.
using (SPSite site = new SPSite("http://servername"))
{
SPServiceContext serviceContext = SPServiceContext.GetContext(site);
try
{
ProfilePropertyManager profilePropMgr = new UserPro... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-work-with-user-profiles-and-organization-profiles-by-using-the-server-obj |
ca4423ba20d8-9 | catch (System.Exception e)
{
Console.WriteLine(e.GetType().ToString() + ": " + e.Message);
Console.Read();
}
}
}
}
}
Code example: Retrieve and change values for user properties by using the SharePoint server object model... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-work-with-user-profiles-and-organization-profiles-by-using-the-server-obj |
ca4423ba20d8-10 | try
{
UserProfileManager userProfileMgr = new UserProfileManager(serviceContext);
ProfilePropertyManager profilePropMgr = new UserProfileConfigManager(serviceContext).ProfilePropertyManager;
// Retrieve all properties for th... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-work-with-user-profiles-and-organization-profiles-by-using-the-server-obj |
ca4423ba20d8-11 | catch (System.Exception e)
{
Console.WriteLine(e.GetType().ToString() + ": " + e.Message);
Console.Read();
}
}
}
}
}
See also
Work with user profiles in SharePoint
How to: Retrieve user profile properties by u... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-work-with-user-profiles-and-organization-profiles-by-using-the-server-obj |
c0347fc226f1-0 | Learn how to retrieve user properties and user profile properties programmatically by using the SharePoint JavaScript object model.
What are user properties and user profile properties in SharePoint?
User properties and user profile properties provide information about SharePoint users, such as display name, em... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-retrieve-user-profile-properties-by-using-the-javascript-object-model-in |
c0347fc226f1-1 | To create an application page that uses the JavaScript object model to retrieve user properties, you'll need:
SharePoint with profiles created for the current user and a target user
Visual Studio 2012
Office Developer Tools for Visual Studio 2013
Full Control connection permissions to access the User P... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-retrieve-user-profile-properties-by-using-the-javascript-object-model-in |
c0347fc226f1-2 | In the markup for the UserProfiles.aspx page, paste the following code inside the "Main" asp:Content tags. This code adds a span control that displays the results of the query, SharePoint:ScriptLink controls that reference SharePoint JavaScript class library files, and script tags to contain your custom logic. ... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-retrieve-user-profile-properties-by-using-the-javascript-object-model-in |
c0347fc226f1-3 | Get the PersonProperties object that represents the target user by using the getPropertiesFor method. (To get the PersonProperties object for the current user, use the getMyProperties method.)
Get a property directly from the PersonProperties object. This example gets the displayName property.
Get... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-retrieve-user-profile-properties-by-using-the-javascript-object-model-in |
c0347fc226f1-4 | // Ensure that the SP.UserProfiles.js file is loaded before the custom code runs.
SP.SOD.executeOrDelayUntilScriptLoaded(getUserProperties, 'SP.UserProfiles.js');
function getUserProperties() {
// Replace the placeholder value with the target user's credentials.
var targetUser = "domainName\\userName";
/... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-retrieve-user-profile-properties-by-using-the-javascript-object-model-in |
c0347fc226f1-5 | // This function runs if the executeQueryAsync call fails.
function onRequestFail(sender, args) {
$get("results").innerHTML = "Error: " + args.get_message();
}
Code example: Retrieving a set of user profile properties by using the getUserProfilePropertiesFor method in the SharePoint JavaScript object model
... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-retrieve-user-profile-properties-by-using-the-javascript-object-model-in |
c0347fc226f1-6 | // Specify the properties to retrieve and target user for the
// UserProfilePropertiesForUser object.
var profilePropertyNames = ["PreferredName", "Department"];
var userProfilePropertiesForUser =
new SP.UserProfiles.UserProfilePropertiesForUser(
clientContext,
targetUser,
... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-retrieve-user-profile-properties-by-using-the-javascript-object-model-in |
f798222db820-0 | Learn how to retrieve user profile properties programmatically by using the SharePoint .NET client object model.
What are user profile properties in SharePoint?
User properties and user profile properties provide information about SharePoint users, such as display name, email, title, and other business and pers... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-retrieve-user-profile-properties-by-using-the-net-client-object-model-in |
f798222db820-1 | To create a console application that uses the .NET client object model to retrieve user profile properties, you'll need the following:
SharePoint with profiles created for the current user and a target user
Visual Studio 2012
Full Control connection permissions to access the User Profile service applicatio... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-retrieve-user-profile-properties-by-using-the-net-client-object-model-in |
f798222db820-2 | Initialize the SharePoint client context, as shown in the following code.
ClientContext clientContext = new ClientContext(serverUrl);
Get the target user's properties from the PeopleManager object, as shown in the following code.
PeopleManager peopleManager = new PeopleManager(clientContext);
PersonPrope... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-retrieve-user-profile-properties-by-using-the-net-client-object-model-in |
f798222db820-3 | foreach (var property in personProperties.UserProfileProperties)
{
Console.WriteLine(string.Format("{0}: {1}",
property.Key.ToString(), property.Value.ToString()));
}
Code example: Retrieving all user profile properties by using the SharePoint .NET client object model
The following code example sh... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-retrieve-user-profile-properties-by-using-the-net-client-object-model-in |
f798222db820-4 | namespace UserProfilesCSOM
{
class Program
{
static void Main(string[] args)
{
// Replace the following placeholder values with the target SharePoint site and
// target user.
const string serverUrl = "http://serverName/";
const string targetUser... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-retrieve-user-profile-properties-by-using-the-net-client-object-model-in |
f798222db820-5 | PeopleManager peopleManager = new PeopleManager(clientContext);
ClientObjectList<PersonProperties> peopleFollowedBy = peopleManager.GetMyFollowers();
clientContext.Load(peopleFollowedBy, people => people.Include(person => person.PictureUrl, person => person.DisplayName));
clientContext.ExecuteQuery();
... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-retrieve-user-profile-properties-by-using-the-net-client-object-model-in |
f798222db820-6 | // Replace the following placeholder values with the target SharePoint site and the
// target user.
const string serverUrl = "http://serverName/";
const string targetUser = "domainName\\\\userName";
// Connect to the client context.
ClientContext clientCo... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-retrieve-user-profile-properties-by-using-the-net-client-object-model-in |
9a49fc4f210f-0 | Create SharePoint-hosted apps that use the REST service to follow content (documents, sites, and tags) and to get followed content.
How do I use the SharePoint REST service to follow content?
SharePoint users can follow documents, sites, and tags to get updates about the items in their newsfeeds and to quickly ... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-follow-documents-sites-and-tags-by-using-the-rest-service-in-sharepoint-2 |
9a49fc4f210f-1 | Note
You also use these endpoints for Following People tasks, but the followers and suggestions resources available from SocialRestFollowingManager only support following people, not content. For more information about how you can use SocialRestFollowingManager , see Follow content in SharePoint and Follow... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-follow-documents-sites-and-tags-by-using-the-rest-service-in-sharepoint-2 |
9a49fc4f210f-2 | You must be logged on as someone other than the system account. The system account does not have permission to install the app.
Note
See Set up an on-premises development environment for SharePoint Add-ins for guidance about on-premises setup (including how to disable the loopback check, if necessary).... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-follow-documents-sites-and-tags-by-using-the-rest-service-in-sharepoint-2 |
9a49fc4f210f-3 | Code example: Start following and stop following a document by using the SharePoint REST service
The following code example represents the contents of the App.js file and shows how to:
Get the app web URI from the query string and construct the <siteUri>/_api/social.following endpoint URI.
Build and se... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-follow-documents-sites-and-tags-by-using-the-rest-service-in-sharepoint-2 |
9a49fc4f210f-4 | // Get the SPAppWebUrl parameter from the query string and build
// the Following manager endpoint.
$(document).ready(function () {
var appweburl;
var params = document.URL.split("?")[1].split("&");
for (var i = 0; i < params.length; i = i + 1) {
var param = params[i].split("=");
if (par... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-follow-documents-sites-and-tags-by-using-the-rest-service-in-sharepoint-2 |
9a49fc4f210f-5 | // Check whether the current user is already following the document.
// The request body includes a SocialActorInfo object that represents
// the specified item.
// The success function reads the response from the REST service and then
// toggles the user's following status by calling the appropriate method.
function ... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-follow-documents-sites-and-tags-by-using-the-rest-service-in-sharepoint-2 |
9a49fc4f210f-6 | // Make the current user start following a document.
// The request body includes a SocialActorInfo object that represents
// the document to follow.
// The success function reads the response from the REST service.
function followDocument() {
$.ajax( {
url: followingManagerEndpoint + "/follow",
typ... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-follow-documents-sites-and-tags-by-using-the-rest-service-in-sharepoint-2 |
9a49fc4f210f-7 | // Make the current user stop following a document.
// The request body includes a SocialActorInfo object that represents
// the document to stop following.
function stopFollowDocument() {
$.ajax( {
url: followingManagerEndpoint + "/stopfollowing",
type: "POST",
data: JSON.stringify( {
... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-follow-documents-sites-and-tags-by-using-the-rest-service-in-sharepoint-2 |
9a49fc4f210f-8 | function requestFailed(xhr, ajaxOptions, thrownError) {
alert('Error:\\n' + xhr.status + '\\n' + thrownError + '\\n' + xhr.responseText);
}
Code example: Start following and stop following a site by using the SharePoint REST service
The following code example represents the contents of the App.js file and ... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-follow-documents-sites-and-tags-by-using-the-rest-service-in-sharepoint-2 |
9a49fc4f210f-9 | // Get the SPAppWebUrl parameter from the query string and build
// the Following manager endpoint.
$(document).ready(function () {
var appweburl;
var params = document.URL.split("?")[1].split("&");
for (var i = 0; i < params.length; i = i + 1) {
var param = params[i].split("=");
if (par... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-follow-documents-sites-and-tags-by-using-the-rest-service-in-sharepoint-2 |
9a49fc4f210f-10 | // Check whether the current user is already following the site.
// The request body includes a SocialActorInfo object that represents
// the specified item.
// The success function reads the response from the REST service and then
// toggles the user's following status by calling the appropriate method.
function isFo... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-follow-documents-sites-and-tags-by-using-the-rest-service-in-sharepoint-2 |
9a49fc4f210f-11 | // Make the current user start following a site.
// The request body includes a SocialActorInfo object that represents
// the site to follow.
// The success function reads the response from the REST service.
function followSite() {
$.ajax( {
url: followingManagerEndpoint + "/follow",
type: "POST",
... | https://learn.microsoft.com/en-us/sharepoint/dev/general-development/how-to-follow-documents-sites-and-tags-by-using-the-rest-service-in-sharepoint-2 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.