cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
tsunatsuna
Helper I
Helper I

Open in client application

Here are details.
I would like to open file which is attached from share point list in client application.
Client application means software installed each computer such as excel or word.
My situation: if I click file, it start to download file. I don't want to download it, just open in client application. Or opening in online such as excel online is also ok.
Please help me and tell how to set in power apps.
1 ACCEPTED SOLUTION

Accepted Solutions

Hi @tsunatsuna ,

 

All the steps seemed perfect.

I suggest you to try in another list to check if it works. Or just delete your current custom form and re-create one. It can be deleted from List settting ➡ Form setting Delete custom form.

Best regards,

Sik

 

View solution in original post

15 REPLIES 15
v-siky-msft
Community Support
Community Support

Hi @tsunatsuna ,

 

Which control do you want to display the control? Display Form?

If you want to click the file in form and open it, the Launch function can be useful to open the file online or in client apps.

However, the Attachment control in the Attachment Data Card is a standard control designed to add, remove, download the attachment files and have no OnSelect property to set. We just try to delete it,  and add a list box instead in the data card.

1. set Items property of listbox as below to display all files

 

ThisItem.Attachments

 

2. set OnSelect property of listbox as below to open the files online.

 

Launch(ListBox1.Selected.AbsoluteUri & "?web=1")

 

3. To two errors, just delete Update property and set Y property properly.

If you want to open the file in client apps, just put 'ms-excel: ofe|u|' (for excel files), or put 'ms-word: ofe|u|'  at the beginning of the link. So change OnSelect property of list box as below, then open excel/word files in client app, open other files online.

 

If(".xls" in ListBox1.Selected.DisplayName,Launch("ms-excel:ofe|u|"&ListBox1.Selected.AbsoluteUri),".doc" in ListBox1.Selected.DisplayName,Launch("ms-word:ofe|u|"&ListBox1.Selected.AbsoluteUri),Launch(ListBox1.Selected.AbsoluteUri & "?web=1"))

 

Annotation 2019-11-04 151436.png

Snipaste_2019-11-04_15-17-22.pngHope this helps.

Best regards,

Sik

If my post is helpful for you, please click on “Accept as Solution” to help other members find it more quickly.

 

Thank you so much @v-siky-msft

I did No.2, but it doesn't work. If I click text, it doesn't open.
Please tell me No.3 more details.

In addition, I can open file in editing mode, but I can't open in viewing mode.

Hi @tsunatsuna ,

 

Do you mean if you set list box's Display Mode to View, you wouldn't open the files?

I think this is fine, View mode is only to display data, have no way for interaction.

To No,3, it is for opening files in client application, you just need to just put 'ms-excel: ofe|u|' (for excel files) before the AbsoluteUri of attachment. e.g. Launch("ms-excel:ofe|u|"&ListBox1.Selected.AbsoluteUri)

Note: 'ms-excel: ofe|u|' is for excel , 'ms-word: ofe|u|' is for word.

If you still have any issue , please post back some screenshots and formula error information, to help you resolve it.

Best regards,

Sik

If my post is helpful for you, please click on “Accept as Solution” to help other members find it more quickly.

Thank you so much @v-siky-msft

 

I mean I would like to open the files in view mode. Because I click the list, it is view mode. In addition to this, I don't want to be edit mode, as I can't allow to edit list.  

Hi @tsunatsuna ,

 

Do you mean the view mode of The Form?

Did you use EditForm? Actually, you can use Display Form, the other field would be in view mode, and attachment list box can still be selected. please see my demo.

Snipaste_2019-11-06_12-59-07.png

Best regards,

Sik 

Thank you for your quick replying @v-siky-msft 

and sorry for my poor explanation.

Here are details:

・It's edit form.

・if Default mode is Edit, I can open file

・if Default mode is view, I can't open it. when I click edit all of list(attached picture2), I can open.

Hi @tsunatsuna ,

 

Yes, I know. 

And I suggest you to use Display Form which would meet your requirement.

Best regards,

Sik

@v-siky-msft 

I see.

please tell me two things;

1.how to change viewform. an error occurs.(attached 12picture)

2.how to pass the data from list. I added field, but it seems it cant have the data.(attached 13picture)

 

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS Attendee Badge

Claim Your Badge & Digital Swag!

Check out how to claim yours today!

secondImage

Are Your Ready?

Test your skills now with the Cloud Skill Challenge.

secondImage

Demo Extravaganza is Back!

We are excited to announce that Demo Extravaganza for 2021 has started!

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Users online (44,147)