Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

microsoftTeams.pages.currentApp.navigateTo not working on Mobile App #2518

Closed
tiennguyen1293 opened this issue Sep 23, 2024 · 4 comments
Closed

Comments

@tiennguyen1293
Copy link

tiennguyen1293 commented Sep 23, 2024

Issue

  • microsoftTeams.pages.currentApp.navigateTo({ pageId, subPageId }) working on Desktop App, but do not working on Mobile App.

Please help me to take a look and resolve this issue, Thanks.

Reproduce Step

  • Initialize App with microsoftTeams.app.initialize()
  • Navigate to Personal Tab on Teams App
  try {
      await microsoftTeams.pages.currentApp.navigateTo({
        pageId,
        subPageId,
      })
  } catch (error) {
    alert(`=== navigateToTeamsTab error:${JSON.stringify(error)} `)
  }
  • Observe Error log

image

Version

Teams iOS Mobile App:

Version: 6.17.1
Build: 6.17.77.2024172601/0914 (general)

Package

 "@microsoft/teams-js": "^2.21.0"
@Prasad-MSFT
Copy link

Thanks for raising your issue. We will check this at our end and will update you accordingly.

@TrevorJoelHarris
Copy link
Contributor

Hi @tiennguyen1293! I'm sorry you are running into a problem with this function. Error code 100 means that the currentApp.navigateTo function is not currently supported on the mobile platform you're trying to call it on. In this case, you should be able to call pages.navigateToApp instead, you will just need to pass it some different parameters (including your own appid).

I'll have someone on our team update the comments on currentApp.navigateTo to add some extra detail about making sure that function is supported.

@Prasad-MSFT I'm not sure if you're the right person for this, but this may be a good thing to notify the Teams iOS team about, they could certainly add support for this if they want.

@tiennguyen1293
Copy link
Author

Hi @TrevorJoelHarris @Prasad-MSFT
Thank you for the quick response!
For the case where I have multiple apps with only one source code, how can I get the AppId for all?

@TrevorJoelHarris
Copy link
Contributor

@tiennguyen1293 Try this and see if it works:

Using the Teams Developer Portal:

  1. Open the Teams Developer Portal: Go to the Teams Developer Portal.
  2. Sign in: Use your Microsoft account to sign in.
  3. Navigate to your app: Find your app in the list of registered apps.
  4. View app details: The appId will be listed in the app details.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants