Events
Power BI DataViz World Championships
Feb 14, 4 PM - Mar 31, 4 PM
With 4 chances to enter, you could win a conference package and make it to the LIVE Grand Finale in Las Vegas
Learn moreThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
This topic applies to Dynamics 365 Customer Engagement (on-premises). For the Power Apps version of this topic, see: Sample: Detect solution dependencies.
This sample shows how to detect dependencies before you delete a solution component. You can download the sample from here.
Note
This sample applies to both Dynamics 365 Customer Engagement (on-premises) and Dataverse.
To obtain a local copy of all samples and build them, follow these steps:
If you don't specify a connection string in dataverse/App.config file, a dialog opens each time you run the sample, and you'll need to enter information about which instance or org you want to connect to and which credentials you want to use. This dialog caches previous connections so that you can choose a previously used connection.
The RetrieveDependentComponentsRequest
, RetrieveDependenciesForDeleteRequest
messages are intended to be used in a scenario where it contains data to detect solution dependencies.
In order to simulate the scenario described in What this sample does, the sample will do the following:
Publisher
method creates the sample publisher that will own
the two solutions.Solution
method creates the primary solution.OptionSetMetadata
creates the global option set and associates it to the solution.ExportSolutionRequest
exports the solution as managed so that we can later import it.DeleteOptionSetRequest
deletes the option set previously created, so it can be imported under the managed solution.ImportSolutionRequest
re-imports the solution as managed.QueryByAttribute
queries all solution components for a solution.RetrieveDependentComponentsRequest
retrieves all the dependencies for the component. If there are no dependencies we can ignore this component. If there are dependencies upon this solution component, and the solution itself is managed, then you will be unable to delete the solution.Display an option to delete the solutions created in Setup. The deletion is optional in case you want to examine the entities and data created by the sample. You can manually delete the records to achieve the same result.
Events
Power BI DataViz World Championships
Feb 14, 4 PM - Mar 31, 4 PM
With 4 chances to enter, you could win a conference package and make it to the LIVE Grand Finale in Las Vegas
Learn moreTraining
Module
Manage solutions in Power Apps and Power Automate - Training
Learn how to manage solutions in Microsoft Power Apps and Power Automate.
Certification
Solution Architects for Finance and Operations apps in Microsoft Dynamics 365 are trusted advisors who understand business recommended practices and software capabilities. They lead team members to implement Dynamics solutions that can achieve the predefined implementation goals.