question

JackLee-7036 avatar image
0 Votes"
JackLee-7036 asked RoyLi-MSFT answered

How to just one-time allow the administrator permission for a Windows Store UWP?

Hello teams,

I have a Windows store app and already uploaded.

But I have an issue about user launch each time will show UAC dialog.

It's because this APP have run as administrator and read/write registry value.

Does any kind method can avoid this UAC dialog without disable UAC?

Thanks for your help:)

windows-uwp
· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

In general, there is no run as administrator option for a native UWP app. Could you please tell me what your app actually does? Is your app a converted app using Desktop bridge and it requires auto-elevation?

0 Votes 0 ·

Hi Sir,

I used the Packaging project with my UWP application.

I have to monitor user's windows mode is desktop or tablet via read/write registry value.

It's a background service and help user can work with their custom hardware device.

Our APP link is https://www.microsoft.com/en-us/p/eh20qt-ns/9p2t9njbp5r3?activetab=pivot:overviewtab

Thanks for your reply.

0 Votes 0 ·

1 Answer

RoyLi-MSFT avatar image
0 Votes"
RoyLi-MSFT answered

Hello,

Welcome to Microsoft Q&A!

UWP apps are running in the sandbox and have limitations when accessing some systems resources. One of them is accessing the registry values. So for native UWP apps, it won't ask for administrator privileges. Based on your description, you are using desktop bridge and maybe you are using some Win32 APIs to read the registry value which requires the administrator privileges. So the behavior you got is excepted. There is no way to make it only push once.

Thank you.


If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.