Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Want to create resource requirement using CRM SDK method

(0) ShareShare
ReportReport
Posted on by

Hi,

I want to create a resource requirement using CRM SDK Method, I tried the below syntax and it throwing error as "Value cannot be null.Parameter name: value"

msdyn_resourcerequirement resourcerequirement = new msdyn_resourcerequirement();
resourcerequirement.msdyn_name = "Test 1";
resourcerequirement.msdyn_allocationmethod = new OptionSetValue(192350000);
resourcerequirement.msdyn_duration = 180;
resourcerequirement.msdyn_IsPrimary = true;
resourcerequirement.msdyn_WorkLocation = new OptionSetValue(690970000);
resourcerequirement.msdyn_Status = new EntityReference("msdyn_requirementstatuses", new Guid("some GUID"));
resourcerequirement.OwnerId = new EntityReference("systemuser", new Guid("some GUID"));
Guid resourcerequirement Id = organizationProxy.Create(resourcerequirement);

Thanks in advance

*This post is locked for comments

  • Suggested answer
    Rawish Kumar Profile Picture
    13,758 on at
    RE: Want to create resource requirement using CRM SDK method

    Hello there,

    please try to debug the code to see in which line this code is failing.

    also a suggestion - make sure you are getting the crm service properly and its not null. see here : community.dynamics.com/.../155508  

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Adis Hodzic – Community Spotlight

We are honored to recognize Adis Hodzic as our May 2025 Community…

Leaderboard > Microsoft Dynamics CRM (Archived)

#1
Mohamed Amine Mahmoudi Profile Picture

Mohamed Amine Mahmoudi 83 Super User 2025 Season 1

#2
Community Member Profile Picture

Community Member 54

#3
Victor Onyebuchi Profile Picture

Victor Onyebuchi 6

Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans