Hi VJ, Thank you for watching and also for informing me about the dll part. Apologies for missing it. However, any project if you want to know what packages are used, you can see that from project file. GraphDemo.csproj github.com/learnsmartcoding/dotnet-app-with-graph-api/blob/main/GraphDemo.csproj We use Microsoft.Graph Hope this helps Thanks, Karthik
Hello Dominic, In Azure AD B2C, you can force users to reset their password upon first login by utilizing the "ForceChangePasswordNextLogin" attribute. When creating a user using the Microsoft Graph API, you can set this attribute to true to require a password change on the user's next login. Sample code below. var newUser = new User { ...other properties PasswordProfile = new PasswordProfile { ForceChangePasswordNextSignIn = true, Password = "new-user-password" } }; Hope this helps you. Happy coding!
Hello, user flow is an interactive process meant to deal with real time through users. Graph api is used to access the ad b2c based on permissions. To answer your question, NO, we can not involve user flow when using a graph. Hope I answer your question
Thanks for pointing, I will check and update if something is missing. The main reason it is throwing an error is that the error is not handled. If you try to update or delete on an object that doesn't exist, this happens.
@@learnsmartcoding That's why I tried firstly to get the object to make sure it's exist then tried to update password it keeps giving error Exception of type 'Microsoft.Graph.Models.ODataErrors.ODataError' was thrown
Weldone bro! This is nicely explained.
Glad you liked it!!
Thank you very much for making this video, but I think missing which dll need to add to solution to work with Graph API, could you please tell.
Hi VJ,
Thank you for watching and also for informing me about the dll part. Apologies for missing it. However, any project if you want to know what packages are used, you can see that from project file.
GraphDemo.csproj
github.com/learnsmartcoding/dotnet-app-with-graph-api/blob/main/GraphDemo.csproj
We use Microsoft.Graph
Hope this helps
Thanks,
Karthik
when created the user from the Graph API, how do we force them to reset password when they first login?
Hello Dominic,
In Azure AD B2C, you can force users to reset their password upon first login by utilizing the "ForceChangePasswordNextLogin" attribute. When creating a user using the Microsoft Graph API, you can set this attribute to true to require a password change on the user's next login. Sample code below.
var newUser = new User
{
...other properties
PasswordProfile = new PasswordProfile
{
ForceChangePasswordNextSignIn = true,
Password = "new-user-password"
}
};
Hope this helps you.
Happy coding!
Is it possible that wen use ghraph to get the user and create and update using userflows.
Hello, user flow is an interactive process meant to deal with real time through users. Graph api is used to access the ad b2c based on permissions. To answer your question, NO, we can not involve user flow when using a graph.
Hope I answer your question
Update and Delete throw Object reference not set to an instance of an object ?
Thanks for pointing, I will check and update if something is missing. The main reason it is throwing an error is that the error is not handled. If you try to update or delete on an object that doesn't exist, this happens.
@@learnsmartcoding That's why I tried firstly to get the object to make sure it's exist then tried to update password it keeps giving error Exception of type 'Microsoft.Graph.Models.ODataErrors.ODataError' was thrown
@@learnsmartcoding Mainly in Change Password Scenario that usually happens !??
@learnsmartcoding Coding have you come up with any Fix for change password issue ?