Skip to content

Commit 4046ed1

Browse files
Merge pull request SharePoint#8670 from sympmarc/patch-6
Changed Code Type
2 parents c648031 + 2c8c093 commit 4046ed1

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

docs/general-development/how-to-add-a-geolocation-column-to-a-list-programmatically-in-sharepoint.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Add a Geolocation column to a list programmatically in SharePoint
33
description: 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.
4-
ms.date: 11/22/2022
4+
ms.date: 01/06/2023
55
ms.prod: sharepoint
66
ms.assetid: f31a3594-c328-4731-b8eb-5da6b85103ad
77
ms.localizationpriority: high
@@ -38,19 +38,19 @@ Follow these steps to add the Geolocation column to a list. This must be done pr
3838
1. Open PowerShell
3939
1. Connect to the site you wish to add the column to
4040

41-
```csharp
41+
```powershell
4242
Connect-PnPOnline -url "https://TENANT.sharepoint.com/sites/SITEURL"
4343
```
4444
4545
1. Open the list you wish to add the column to
4646
47-
```csharp
47+
```powershell
4848
$list = Get-PnPList -Identity "LISTNAME"
4949
```
5050
5151
1. #Add the Geolocation field - Change parameters as necessary
5252
53-
```csharp
53+
```powershell
5454
Add-PnPField -List $list -Type GeoLocation -DisplayName "GeoLocationField" -InternalName "GeoLocationField" -AddToDefaultView -Required
5555
```
5656

0 commit comments

Comments
 (0)