Now, we will be using the following code in our Run method where we will be calling another method, CreateContacts, to process the CSV file.
Here is the code to process CSV files from myblob storage-
The above code will read CSV files from Blob storage into the data table and will check if the same record exists with a combination of first name, last name and email. It will call the update method otherwise it will create it.
And we can use the following method to connect to Dynamics 365 organization.
Keep in mind to connect using hardcoded credentials also we need include following references in our Azure function trigger. We can include the reference for ActiveDirectory assembly in project.json just like we did for Dynamics 365 V 8.