Search code examples
azurevisual-studioazure-subscription

Visual Studio not showing subscription from other account - just happened last week


I have my personal Azure account having 2 subscriptions.

Those subscriptions are visible in Visual Studio 2022 when trying to publish a project.

From another account, I have owner access to that subscription and it was showing perfectly in Visual Studio when trying to publish. Suddenly since last week, this subscription is not visible in Visual Studio anymore.

I already checked from the other account if I lost access to the subscription but Im still the owner. Nothing has changed.

Any clue if Microsoft changed something?

Thanks


Solution

  • I logged in to Visual Studio with my other account but cannot see the subscriptions as you can see below:

    enter image description here

    Cause: Then I understood what was going on here. The user who will be created as the tenant's owner belongs under External User, and the user who will be explicitly created under a specific tenant will have appropriate access on the Subscription level depending on the RBAC Assignments.

    So, here I created a new user and provided the "global administrator role" and gave owner role of the specific subscription.

    enter image description here

    enter image description here

    Note: If you look closely, you'll notice that the 'User Principal Name' field for the 'Tenant Owner' has been extended with the keyword EXT, which refers to the Microsoft External User as shown in the below image.

    enter image description here

    Now, When I log in to Visual Studio with that created user's credentials, I can view the Subscriptions and perform all the required actions.

    enter image description here

    There can be multiple reasons for not visibility of Subscriptions in Visual Studio IDEs like "Cache Problem, IDE Update Problem, different types of Accounts" etc.

    Refer SO & MSDoc for the relevant information related to the sign in issues.

    Let's say if you have cache issue:

    Need to check:

    1. Goto the account settings in the Visual Studio as shown.
    2. Remove all the existed accounts or sign out from the accounts.
    3. Restart the Visual studio and re-enter with your credentials.

    Sometimes this will help to resolve this issue.

    enter image description here