Skip to content

Commit ec3f077

Browse files
committed
Merge branch 'main' into 2920661
2 parents 53e05a6 + dd2fb1a commit ec3f077

18 files changed

+126
-135
lines changed

powerapps-docs/developer/data-platform/auditing/overview.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,9 @@ Audit history data is stored in the [Auditing (Audit) table](../reference/entiti
7373

7474
More information: [Retrieve the history of audited data change](retrieve-audit-data.md)
7575

76+
> [!IMPORTANT]
77+
> Audit history is not available for tables in the mobile app.
78+
7679
## Delete audit data
7780

7881
You may need to delete audit data because:
@@ -100,4 +103,4 @@ More information: [Delete audit data](delete-audit-data.md)
100103
[Retrieve the history of audited data changes](retrieve-audit-data.md)<br />
101104
[Delete audit data](delete-audit-data.md)
102105

103-
[!INCLUDE[footer-include](../../../includes/footer-banner.md)]
106+
[!INCLUDE[footer-include](../../../includes/footer-banner.md)]

powerapps-docs/developer/data-platform/dataverse-odata-dataflows-migration.md

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,23 @@
11
---
22
title: Migrate data between Microsoft Dataverse environments using the dataflows OData connector
33
author: denisem-msft
4-
ms.reviewer: "nabuthuk"
4+
ms.reviewer: jdaly
55
description: Migrate data between Microsoft Dataverse environments using dataflows OData connector.
6-
ms.date: 11/24/2021
7-
ms.topic: "article"
6+
ms.date: 10/03/2022
7+
ms.topic: article
88
ms.subservice: dataverse-developer
99
ms.author: demora
1010
search.app:
1111
- PowerApps
12+
contributors:
13+
- JimDaly
1214
---
1315

1416
# Migrate data between Microsoft Dataverse environments using the dataflows OData connector
1517

16-
18+
> [!NOTE]
19+
> Consider using the [Power Query Dataverse Connector](/power-query/connectors/dataverse) with Dataflows rather than the OData connector.
20+
> Dataflows are the recommended method to migrate data between Dataverse environments. More information [What are dataflows?](/power-query/dataflows/overview-dataflows-across-power-platform-dynamics-365)
1721
1822
Dataverse [Web API](./webapi/overview.md) works with any technology that supports OData and OAuth. There are many options available to move data in and out of Dataverse. OData connector is one of the dataflows, which is designed to support migration and synchronization of large datasets in Dataverse.
1923

powerapps-docs/developer/data-platform/dependent-assembly-plugins.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -347,6 +347,10 @@ More information:
347347

348348
The following are known issues that should be resolved before dependent assemblies for plug-ins becomes generally available.
349349

350+
### Asynchronous plug-in steps do not work
351+
352+
If you use dependent assemblies for a plug-in registered for an asynchronous step an error with the message `Expected non-empty Guid.` will occur.
353+
350354
### Plug-in profiler
351355

352356
You cannot use Plug-in Profiler to debug plug-ins that are part of a plug-in package. More information: [Use Plug-in profiler](debug-plug-in.md#use-plug-in-profiler)

powerapps-docs/developer/data-platform/developer-tools.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ Developers will use the following tools and resources when working with solution
2424

2525
*Power Platform Tools for Visual Studio* - supports the rapid creation, debugging, and deployment of plug-ins. Other capabilities currently in preview include development of custom workflow activities, web resources, integration technologies like Azure Service endpoints and webhooks, and more. To learn more about the tool, install the [extension](tools/devtools-install.md) and try the available [quickstart](tools/devtools-create-project.md) topics.
2626

27-
*Microsoft Power Platform CLI* - a simple, one-stop developer CLI that empowers developers and ISVs to perform various operations in Microsoft Power Platform related to environment lifecycle features, and to authenticate and work with Microsoft Dataverse environments, solution packages, portals, code components, and so on. To learn more about the tool, install the [extension](powerapps-cli.md#install-microsoft-power-platform-cli) or try the available [standalone](powerapps-cli.md#standalone-power-platform-cli) version.
27+
*Microsoft Power Platform CLI* - a simple, one-stop developer CLI that empowers developers and ISVs to perform various operations in Microsoft Power Platform related to environment lifecycle features, and to authenticate and work with Microsoft Dataverse environments, solution packages, portals, code components, and so on. To learn more about the tool, see [What is Microsoft Power Platform CLI?](powerapps-cli.md).
2828

2929
## Tools available for download from NuGet
3030

Loading
Loading
Loading

powerapps-docs/developer/data-platform/org-service/TOC.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
href: overview.md
55
- name: Get started
66
items:
7-
- name: 'Quickstart: Create a console app'
7+
- name: 'Quickstart: Execute service request'
88
href: quick-start-org-service-console-app.md
99
- name: Late and Early-bound programming
1010
href: early-bound-programming.md

powerapps-docs/developer/data-platform/org-service/iorganizationservice-interface.md

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
22
title: "IOrganizationService Interface (Microsoft Dataverse) | Microsoft Docs" # Intent and product brand in a unique string of 43-59 chars including spaces
3-
description: "Learn about the common methods exposed to perform data operations with Microsoft Dataverse." # 115-145 characters including spaces. This abstract displays in the search result.
3+
description: "Learn about the common web service methods exposed to perform data operations in Microsoft Dataverse." # 115-145 characters including spaces. This abstract displays in the search result.
44
ms.custom: intro-internal
5-
ms.date: 03/22/2022
5+
ms.date: 09/30/2022
66
ms.reviewer: "pehecke"
77
ms.topic: "article"
88
author: "divka78" # GitHub ID
@@ -14,32 +14,28 @@ search.app:
1414
- PowerApps
1515
- D365CE
1616
contributors:
17-
- PHecke
17+
- phecke
1818
- JimDaly
1919
---
2020

2121
# IOrganizationService Interface
2222

2323
[!INCLUDE[cc-terminology](../includes/cc-terminology.md)]
2424

25-
The <xref:Microsoft.Xrm.Sdk.IOrganizationService> interface provides a set of methods used to perform the most common operations on system and custom tables and on the table definitions for your organization.
25+
The <xref:Microsoft.Xrm.Sdk.IOrganizationService> interface exposes methods used to perform web service operations on system and custom tables and on the table definitions (metadata) for your environment.
2626

2727
## Client applications
2828

29-
This interface is implemented in a number of classes that you can use in your code when creating client applications.
29+
This interface is implemented by a couple of classes that you can use in your code when creating client applications.
3030

3131
|Class|Description|
3232
|--|--|
33-
|<xref:Microsoft.Xrm.Sdk.Client.OrganizationServiceProxy>|This is the original low-level class which is used by WCF and the Organization service endpoint |
34-
|<xref:Microsoft.Xrm.Sdk.WebServiceClient.OrganizationWebProxyClient>|This low-level class was created to enable OAuth authentication to the Organization service endpoint|
35-
|<xref:Microsoft.Xrm.Tooling.Connector.CrmServiceClient>|This is the class you should use when creating .NET client applications. |
36-
37-
> [!NOTE]
38-
> You may find older code or samples using the low-level <xref:Microsoft.Xrm.Sdk.Client.OrganizationServiceProxy> or <xref:Microsoft.Xrm.Sdk.WebServiceClient.OrganizationWebProxyClient> classes, but we recommend you use <xref:Microsoft.Xrm.Tooling.Connector.CrmServiceClient> for new .NET Client applications
33+
|<xref:Microsoft.Xrm.Tooling.Connector.CrmServiceClient>|This is the class you should use when creating .NET Framework client applications. |
34+
|<xref:Microsoft.PowerPlatform.Dataverse.Client.ServiceClient>|This is the class you should use when creating .NET Framework or .NET Core client applications. |
3935

4036
## Plug-ins
4137

42-
When you write plug-ins, there is also an object returned from the <xref:Microsoft.Xrm.Sdk.IOrganizationServiceFactory>.<xref:Microsoft.Xrm.Sdk.IOrganizationServiceFactory.CreateOrganizationService(System.Nullable{System.Guid})> which implements the <xref:Microsoft.Xrm.Sdk.IOrganizationService> interface but is not any of the types in the classes above.
38+
When you write plug-ins, there is also an object returned from the <xref:Microsoft.Xrm.Sdk.IOrganizationServiceFactory>.<xref:Microsoft.Xrm.Sdk.IOrganizationServiceFactory.CreateOrganizationService(System.Nullable{System.Guid})> which implements the <xref:Microsoft.Xrm.Sdk.IOrganizationService> interface but is not any of the types in the service client classes above.
4339

4440
## IOrganizationService Methods
4541

Lines changed: 65 additions & 72 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
---
2-
title: "Quickstart: Organization service sample (C#) (Microsoft Dataverse) | Microsoft Docs" # Intent and product brand in a unique string of 43-59 chars including spaces
3-
description: "This quickstart will show you how to connect to the organization service of the Microsoft Dataverse" # 115-145 characters including spaces. This abstract displays in the search result.
4-
ms.date: 04/03/2022
5-
author: JimDaly
6-
ms.author: jdaly
2+
title: "Quickstart: Execute an Organization service request (C#) (Microsoft Dataverse) | Microsoft Docs" # Intent and product brand in a unique string of 43-59 chars including spaces
3+
description: "Demonstrates how to connect to the Organization service of Microsoft Dataverse and execute a request." # 115-145 characters including spaces. This abstract displays in the search result.
4+
ms.date: 10/05/2022
5+
author: phecke
6+
ms.author: pehecke
77
manager: kvivek
8-
ms.reviewer: pehecke
8+
ms.reviewer: jdaly
99
ms.topic: "article"
1010
search.audienceType:
1111
- developer
@@ -16,129 +16,122 @@ contributors:
1616
- JimDaly
1717
- phecke
1818
---
19-
# Quickstart: Organization service sample (C#)
2019

21-
[!INCLUDE[cc-terminology](../includes/cc-terminology.md)]
20+
# Quickstart: Execute an Organization service request (C#)
2221

23-
This is where you begin working with the .NET SDK assemblies to work with data using Microsoft Dataverse.
22+
[!INCLUDE[cc-terminology](../includes/cc-terminology.md)]
2423

25-
In this quickstart, you will create a minimum console application to connect to the Organization service using the <xref:Microsoft.Xrm.Tooling.Connector.CrmServiceClient> class. You will pass your connection information using a connection string passed to the constructor.
24+
This topic shows you how to begin using classes in the SDK for .NET assemblies to work with Microsoft Dataverse business data. You will create a minimal console application to connect to your environment's Organization service using the <xref:Microsoft.PowerPlatform.Dataverse.Client.ServiceClient> class and execute a web service operation.
2625

27-
You will use the <xref:Microsoft.Xrm.Sdk.IOrganizationService>.<xref:Microsoft.Xrm.Sdk.IOrganizationService.Execute*> method passing an instance of the <xref:Microsoft.Crm.Sdk.Messages.WhoAmIRequest> class, and you will display the <xref:Microsoft.Crm.Sdk.Messages.WhoAmIResponse>.<xref:Microsoft.Crm.Sdk.Messages.WhoAmIResponse.UserId> value.
26+
Your application will call the <xref:Microsoft.Xrm.Sdk.IOrganizationService>.<xref:Microsoft.Xrm.Sdk.IOrganizationService.Execute*> method passing an instance of the <xref:Microsoft.Crm.Sdk.Messages.WhoAmIRequest> class. The result returned from the web service is a populated <xref:Microsoft.Crm.Sdk.Messages.WhoAmIResponse>.<xref:Microsoft.Crm.Sdk.Messages.WhoAmIResponse.UserId> value which is the unique identifier of your Dataverse system user account.
2827

2928
> [!NOTE]
30-
> This quickstart example does not include error handling. This is a minimum example of what you need to connect to and use the Organization service.
29+
> This quick start example does not include exception handling for brevity. This is a minimum code example of what you need to connect to and use the Organization service.
3130
31+
You can download the complete code sample from GitHub [quickstart-execute-request](https://github.com/microsoft/PowerApps-Samples/blob/master/dataverse/orgsvc/C%23-NETCore/GetStarted/quickstart-execute-request/).
3232

3333
## Prerequisites
3434

35-
- Visual Studio (2019 recommended)
35+
- Visual Studio (2019 or later)
3636
- Internet connection
37-
- Valid user account for a Dataverse instance
38-
- Your username
39-
- Your password
40-
- Url to the Dataverse environment you want to connect with
37+
- Logon credentials of a Dataverse system user account for the target environment
38+
- URL address of the Dataverse environment you want to connect with
4139
- Basic understanding of the Visual C# language
4240

4341
## Create Visual Studio project
4442

45-
1. Create a new Console App (.NET Framework) project using .NET Framework 4.6.2
43+
1. Create a new .NET console app project. For this project we are using Visual Studio 2022 and targeting .NET 6, but .NET Framework will also work.
4644

4745
![Start a console app project.](../media/quick-start-org-service-console-app-1.png)
4846

49-
> [!NOTE]
50-
> This screenshot shows the name `OrgServiceQuickStart`, but you can choose to name the project and solution whatever you want.
51-
5247
1. In **Solution Explorer**, right-click the project you created and select **Manage NuGet Packages...** in the context menu.
5348

5449
![Add NuGet package.](../media/quick-start-org-service-console-app-2.png)
5550

56-
1. Browse for the latest version of the `Microsoft.CrmSdk.XrmTooling.CoreAssembly` NuGet package and install it.
51+
1. Browse for the latest version of the `Microsoft.PowerPlatform.Dataverse.Client` NuGet package and install it.
5752

58-
![Install Microsoft.CrmSdk.XrmTooling.CoreAssembly NuGet package.](../media/quick-start-org-service-console-app-3.png)
53+
![Install Microsoft.PowerPlatform.Dataverse.Client NuGet package.](../media/quick-start-org-service-console-app-3.png)
5954

6055
> [!NOTE]
61-
> You must select **I Accept** in the **Licence Acceptance** dialog.
56+
> Your will be prompted to OK the preview changes, and then select **I Accept** in the **Licence Acceptance** dialog.
6257
63-
## Edit Program.cs
58+
## Add application code
6459

65-
1. Add these using statements to the top of `Program.cs`
60+
1. In **Solution Explorer**, double-click Program.cs to edit that file. Replace the file's contents with the code shown below.
6661

6762
```csharp
6863
using Microsoft.Crm.Sdk.Messages;
69-
using Microsoft.Xrm.Tooling.Connector;
70-
```
71-
72-
1. Replace the `Main` method with the following code. The supported values for *AuthType* are listed in [Connection string parameters](../xrm-tooling/use-connection-strings-xrm-tooling-connect.md).
73-
74-
```csharp
75-
static void Main(string[] args)
76-
{
77-
// e.g. https://yourorg.crm.dynamics.com
78-
string url = "<your environment url>";
79-
80-
string userName = "<your user name>";
81-
// e.g. y0urp455w0rd
82-
string password = "<your password>";
83-
84-
string conn = $@"
85-
Url = {url};
64+
using Microsoft.PowerPlatform.Dataverse.Client;
65+
66+
class Program
67+
{
68+
// TODO Enter your Dataverse environment's URL and logon info.
69+
static string url = "https://yourorg.crm.dynamics.com";
70+
static string userName = "[email protected]";
71+
static string password = "password";
72+
73+
// This service connection string uses the info provided above.
74+
// The AppId and RedirectUri are provided for sample code testing.
75+
static string connectionString = $@"
8676
AuthType = OAuth;
77+
Url = {url};
8778
UserName = {userName};
8879
Password = {password};
8980
AppId = 51f81489-12ee-4a9e-aaae-a2591f45987d;
9081
RedirectUri = app://58145B91-0C36-4500-8554-080854F2AC97;
9182
LoginPrompt=Auto;
9283
RequireNewInstance = True";
9384

94-
using (var svc = new CrmServiceClient(conn))
85+
static void Main(string[] args)
9586
{
96-
97-
WhoAmIRequest request = new WhoAmIRequest();
98-
99-
WhoAmIResponse response = (WhoAmIResponse)svc.Execute(request);
100-
101-
Console.WriteLine("Your UserId is {0}", response.UserId);
102-
87+
using (ServiceClient serviceClient = new(connectionString))
88+
{
89+
if (serviceClient.IsReady)
90+
{
91+
WhoAmIResponse response =
92+
(WhoAmIResponse)serviceClient.Execute(new WhoAmIRequest());
93+
94+
Console.WriteLine("User ID is {0}.", response.UserId);
95+
}
96+
else
97+
{
98+
Console.WriteLine(
99+
"A web service connection was not established.");
100+
}
101+
}
102+
103+
// Pause the console so it does not close.
103104
Console.WriteLine("Press any key to exit.");
104105
Console.ReadLine();
105106
}
106107
}
107108
```
108109

109-
1. Edit the following values to add information for your environment. You can find your environment URL in the Web application under **Settings > Customization > Developer Resources**.
110+
1. Change the values for the environment URL, username, and password as indicated by the TODO code comment.
110111

111-
```csharp
112-
// e.g. https://yourorg.crm.dynamics.com
113-
string url = "<your environment url>";
114-
115-
string userName = "<your user name>";
116-
// e.g. y0urp455w0rd
117-
string password = "<your password>";
118-
```
112+
> [!NOTE]
113+
> You can find supported values for *AuthType* listed in [Connection string parameters](../xrm-tooling/use-connection-strings-xrm-tooling-connect.md#connection-string-parameters). You can find your environment URL in the legacy web application under **Settings > Customization > Developer Resources** or in Power Apps **Settings** (gear icon) > **Developer Resources**.
114+
>
115+
> While this code sample places the username/password information in the code for simplicity, other code samples will use the more recommended approach of prompting for that information or storing it in a separate App.config or appsettings.json file.
119116

120117
## Run the program
121118

122-
1. Press F5 to run the program. The output should look like this:
119+
1. Press F5 to run the program. The output should look something like this:
123120

124121
```bash
125-
Your UserId is 969effb0-98ae-478c-b547-53a2968c2e75
122+
User ID is 969effb0-98ae-478c-b547-53a2968c2e75
126123
Press any key to exit.
127124
```
128125

129-
### Congratulations!
130-
131-
You have successfully connected to the organization service.
132-
133126
## Next Steps
134127

135-
These articles will explain how to work with Dataverse tables:
128+
The console app demonstrates how to connect to the Organization web service using a connection string, execute a web service message request, and access some data in the response. Next, you may want to look at common web service data operations like create, retrieve, update, and delete.
136129

137-
[Entity class operations using the Organization service](entity-operations.md)<br />
138-
[Create table rows using the Organization Service](entity-operations-create.md)<br />
139-
[Retrieve a table row using the Organization Service](entity-operations-retrieve.md)<br />
130+
The following articles will explain how to work with business data in Dataverse tables.
131+
[Entity class operations using the Organization service](entity-operations.md)
132+
[Create table rows using the Organization Service](entity-operations-create.md)
133+
[Retrieve a table row using the Organization Service](entity-operations-retrieve.md)
140134
[Update and delete table rows using the Organization Service](entity-operations-update-delete.md)<br />
141135
[Associate and disassociate table rows using the Organization Service](entity-operations-associate-disassociate.md)
142136

143-
144-
[!INCLUDE[footer-include](../../../includes/footer-banner.md)]
137+
[!INCLUDE[footer-include](../../../includes/footer-banner.md)]

0 commit comments

Comments
 (0)