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

Unable to open documents in a SharePoint library from a Teams tab app #10060

Open
1 of 9 tasks
vvf-cyc opened this issue Dec 22, 2024 · 0 comments
Open
1 of 9 tasks

Unable to open documents in a SharePoint library from a Teams tab app #10060

vvf-cyc opened this issue Dec 22, 2024 · 0 comments

Comments

@vvf-cyc
Copy link

vvf-cyc commented Dec 22, 2024

What type of issue is this?

Question

What SharePoint development model, framework, SDK or API is this about?

💥 SharePoint Framework

Target SharePoint environment

SharePoint Online

What browser(s) / client(s) have you tested

  • 💥 Internet Explorer
  • 💥 Microsoft Edge
  • 💥 Google Chrome
  • 💥 FireFox
  • 💥 Safari
  • mobile (iOS/iPadOS)
  • mobile (Android)
  • not applicable
  • other (enter in the "Additional environment details" area below)

Additional environment details

New Teams
Teams tab app (Teams Toolkit)
SharePoint Online

Issue description

I have an application designed for Teams (tab type) that allows navigation through several SharePoint document libraries. However, I’ve noticed that when I try to open a document from the library within the tab app, nothing happens, neither in Teams nor in the desktop app. To open the documents, I need to go to the SharePoint site in a browser, where I can open them without any problem.

I’ve noticed that document libraries are displayed differently in the Teams tab app compared to how they are displayed in SharePoint in a browser. This happens because the library URL automatically includes 'filebrowser.aspx', which I believe is a feature used by Teams to display SharePoint libraries in a way that better fits its design.

The URL generated to access a library looks like this:
https://TENANT.sharepoint.com/sites/SITENAME/_layouts/15/filebrowser.aspx?**app=teamsfile**&**scenario=teamsPage**&auth=none&fileBrowser=DOCUMENT&theme={theme}

If I remove 'app=teamsfile' from the URL, it redirects me to a different iframe than the one in Teams, which does allow documents to be opened without issues.

The problem is that in the .zip generated by the tab app to configure the URLs, these parameters are not specified. The URLs defined in this file have the following format:
https://tenant.sharepoint.com/sites/SITENAME/_layouts/15/teamslogon.aspx?SPFX=true&dest=/sites/SITENAME/SitePages/PAGENAME.aspx?env=WebViewList

Originally, this Teams tab app was designed for the classic version of Teams. However, since the update to the new Teams, these issues seem to have emerged. Additionally, I’ve found another issue that seems related to the same problem: #9316

Therefore, I would like to know if there is any way to resolve this issue so I can open documents from a SharePoint library without any problems from the Teams tab app. I’m unsure whether the solution might involve avoiding the use of 'filebrowser.aspx' or the 'app=teamsfile' parameter.

I turn to the wisdom of the community. Thank you very much in advance.

@vvf-cyc vvf-cyc changed the title Unable to open documents in a SharePoint library from an app for Teams Unable to open documents in a SharePoint library from a Teams tab app Dec 22, 2024
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

1 participant