Hi all,
I've a personal table in Dynamics 365 sales, where I store my "opportunities" files.
I need to find the variable PATH of file that I upload on the table and save it on the same row of the file in a specific column.
Thanx for any suggestion.
Hi all,
I've a personal table in Dynamics 365 sales, where I store my "opportunities" files.
I need to find the variable PATH of file that I upload on the table and save it on the same row of the file in a specific column.
Thanx for any suggestion.
Hi DiePic ,
The CRM Domain is your CRM instance domain which you find from CRM URL and in URL end I have used entity Plural name with account record id in () to access that record related data. please see below example to get more idea.
Example:
Here I have attachment field (Datatype is File)in my account entity, now I have attached 1 document for org-2 account record. By hovering on file you will get document download link which I have highlighted in below screenshot. also you can get link by right click on file name and copy the link.
This link is in below format.
https://<CRM_Domain>/api/data/v9.1/contacts(<contact_id>)/cr947_filecontent/
Here is the result of file in base64 format which I have uploaded for account:
Hope this helps!
Thanks.
Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365.
Hi DiePic,
Open a record and you can get <CRM_Domain> in the url:
There are two part in the "contacts(<contact_id>)".
First, "contacts" is the plural form of a table logical name. You can find the logical name here:
And the "contact id", you could open the record which you want to get it's file in the "MyDocuments" table( You personal table) and can find it in the url:
And the "cr947_filecontent" is the logical name of the file field in your "MyDocuments" table.
Thank you for reply @Maulik Shah
I'm new in this programs and I've a lot of difficulties to understand. Please can you give me some example?
https://<CRM_Domain>/api/data/v9.1/contacts(<contact_id>)/cr947_filecontent/$value?size=full
There is a sure way to obtain this data underlined blue parameters?
Hi DiePic ,
How you will manage your documents in your custom entity(table)?
If you using File DataType field for your custom entity then that field file will b e stored in Azure Blob and you can directly access this file by below format.
Below is the URL Format to download the file content for a file field for a contact record.
https://<CRM_Domain>/api/data/v9.1/contacts(<contact_id>)/cr947_filecontent?size=full – This will download the content in base64 format string.
https://<CRM_Domain>/api/data/v9.1/contacts(<contact_id>)/cr947_filecontent/$value?size=full – This will download the content as byte array.
Also check below links for File type information:
https://nishantrana.me/2021/10/01/using-file-and-image-data-type-in-dataverse-dynamics-365/
https://debajmecrm.com/new-data-type-filein-cds-all-you-may-need-to-know-about-it/
I hope it helps,
Thanks.
Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365.
Hi Abdul Wahab,
thank you for replay ... I'm talking about a personal table "MyDocuments", where I store some file of "opportunities".
All it's working, but I dont know how find the "path variable" and insert in relative column
Hi DIE PIC,
Do you mean share point location? If Yes then Here you are
If I answer your question then please mark it as verified.
Let me know if I can provide you with more details.
Thanks
Regards,
Abdul Wahab
Power Platform/Customer Engagement Developer/Lead/Solution Architecture/Project Manager
Direct/WhatsApp:+923323281237
E-mail: abdulwahabubit@outlook.com
Skype: abdul.wahabubit
Linkedin: www.linkedin.com/.../
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 290,263 Super User 2024 Season 2
Martin Dráb 228,112 Most Valuable Professional
nmaenpaa 101,148