How to add Syncfusion references and Xamarin packages in DataGrid samples?
In all our getting started samples and KB samples you could see that if you deploy it directly after downloading there will be some errors thrown regarding missing packages. This is because we would have only linked the Syncfusion and Xamarin references rather than attaching the dlls along with the provided samples. So in order to run the samples you have to add the references manually, which is explained below.
Adding Syncfusion references
You can find all the required assemblies from the installation folder mentioned below once you have installed Essential Studio for Xamarin. In Mac assemblies can be found in unzipped package location.
{Syncfusion Essential Studio Installed location}\Essential Studio\{ReleaseVersion}\lib
Eg: C:\Program Files (x86)\Syncfusion\Essential Studio\13.4.0.53\lib
For more details regarding adding Syncfusion references refer the following User Documentation link
https://help.syncfusion.com/xamarin/sfdatagrid/getting-started
Adding Xamarin Nugets
By default the Xamarin Studio and Visual Studio IDE provides options to restore the nugget packages.
If the packages are not restored successfully or if you find any other errors after restoring then follow the below steps to add them manually.
If Xamarin packages are not added to your project or if there is any conflict in the added packages, the references section of your project will look like this.
In such case follow the below steps to manually uninstall the existing packages and re-install the packages.
- Remove all the package references.
- If you are using VisualStudio open the PackageManagerConsole from Tools -> NuggetPackageManager -> PackageManagerConsole and type the following command to install specific version of Xamarin Packages.
Install-Package Xamarin.Forms -Version 1.5.1.647
If you are using XamarinStudio then do the following
- Right click the packages section in the solution explorer and select remove packages and then again right click packages section and select add packages
- Then type “Xamarin.Forms version:*” in the search bar at the top right corner of the Dialog Box to get all versions of Xamarin.Forms . Now choose the desired version to install them in your project.
- Now repeat the steps 1 and 2 for all the projects in the solution. In Visual Studio ensure to change the target solution while installing Xamarin Packages like shown below
By this way you can add all the Syncfusion references and the Xamarin packages and run the sample.