title: How to check if a device is AD joined or Azure AD joined/registered?
body: <p>I need to check if my device is local Domain Joined or Azure AD joined/registered. How to check this? I tried <a href="https://docs.microsoft.com/en-us/windows/desktop/api/lmjoin/nf-lmjoin-netgetjoininformation" rel="nofollow noreferrer">NetGetJoinInformation</a> and could not get anything for Azure AD joined scenario. Can anyone point me in the right direction?</p>