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

Drag&Drop does not work with within Elevated Apps #7690

Open
1 of 2 tasks
davidegiacometti opened this issue Sep 5, 2022 · 22 comments
Open
1 of 2 tasks

Drag&Drop does not work with within Elevated Apps #7690

davidegiacometti opened this issue Sep 5, 2022 · 22 comments
Labels
bug Something isn't working feature proposal New feature proposal product-winui3 WinUI 3 issues team-Markup Issue for the Markup team

Comments

@davidegiacometti
Copy link

Describe the bug

Reorder a ListView with drag&drop make the app crash when running elevated.

Steps to reproduce the bug

  1. Build https://github.com/davidegiacometti/listview-crash
  2. Run as normal user
  3. Reorder the ListView with drag&drop: working
  4. Retry running elevated: Catastrophic failure (0x8000FFFF (E_UNEXPECTED))

Expected behavior

Working when running elavated

Screenshots

No response

NuGet package version

WinUI 3 - Windows App SDK 1.1.4

Windows app type

  • UWP
  • Win32

Device form factor

Desktop

Windows version

Windows 10 (21H2): Build 19044

Additional context

No response

@davidegiacometti davidegiacometti added the bug Something isn't working label Sep 5, 2022
@ghost ghost added the needs-triage Issue needs to be triaged by the area owners label Sep 5, 2022
@bpulliam bpulliam added product-winui3 WinUI 3 issues Crash whenever user reports a crash or app freeze labels Oct 12, 2022
@bpulliam
Copy link
Contributor

Does this issue repro after 1.2-preview2? There were significant Drag and Drop fixes in that release (all of which are in 1.2 stable).

@bpulliam bpulliam added the team-Markup Issue for the Markup team label Oct 29, 2022
@davidegiacometti
Copy link
Author

Still persists with latest preview.

@MikeHillberg
Copy link
Contributor

There's a limitation currently that drag/drop isn't supported in apps running elevated

https://learn.microsoft.com/en-us/windows/apps/windows-app-sdk/stable-channel#elevation

@davidegiacometti
Copy link
Author

Hi @MikeHillberg
Thank you! I totally missed that.
Is there an official issue tracking this or should I leave this opened?

@MikeHillberg
Copy link
Contributor

I don't see it in Issues either, let's leave this one. And thanks for opening

@bpulliam
Copy link
Contributor

I changed the title for clarity.

@bpulliam bpulliam changed the title ListView Drag&Drop Reorder Crash Drag&Drop does not work with Elevated Apps Nov 17, 2022
@bpulliam bpulliam added feature proposal New feature proposal and removed needs-triage Issue needs to be triaged by the area owners Crash whenever user reports a crash or app freeze labels Nov 17, 2022
@Petrarca181
Copy link

Was this solved? At current state 1.3, When I drag on elevated app I see ban icon.

@Scottj1s
Copy link
Member

@Petrarca181 I think you're referring to dragging external content into the elevated app? That would present the ban icon, and is a behavior of Windows. You can repro by running Notepad as admin, and attempting to drag a txt file into.

@Scottj1s Scottj1s changed the title Drag&Drop does not work with Elevated Apps Drag&Drop does not work with within Elevated Apps Apr 17, 2023
@jaimecbernardo
Copy link

Starting to drag a Border in an elevated app also crashes due to it being unsupported. Why is this in the Freezer? It sounds like being able to drag UI elements is a useful part of many UIs.

@bpulliam bpulliam removed the bug Something isn't working label Jul 1, 2023
@martgoodall
Copy link

martgoodall commented Aug 10, 2023

I have exactly the same issue/senario with

                 <GridView x:Name="GridViewDevices"
                           CanDragItems="True"
                           SelectionMode="Extended"
                           ItemsSource="{x:Bind ItemsSourceDevices, Mode=TwoWay}"
                           Loaded="{x:Bind LoadedStartConnectedAnimationForBackNavigationDevices}"
                           ItemsPanel="{StaticResource ItemsPanelTemplateDevices}"
                           ItemTemplate="{StaticResource DataTemplateDevices}"
                           ContainerContentChanging="ContainerContentChangingDevices"/>

If i run code in visualstudio 2022 and start normally, all is good. If i start VS as admin, code segs on start of drag.
Im running windowsappsdk 1.3.230724000 (everything else is latest too). debugger shows the event "catastrophic issue"

@ghord
Copy link

ghord commented Oct 12, 2023

Any update on this? Application crashing in elevated mode when user initiates drag is horrible experience.

Simple functionality like CanReorderItems simply crashes the app...

@martgoodall
Copy link

sadly I just upgraded to [1.4.2 (1.4.231008000)] (https://learn.microsoft.com/en-us/windows/apps/windows-app-sdk/stable-channel#version-142-14231008000) and the bug still exists. code crashes with "catastrophic error" when Admin and drag and drop is performed, but works fine if not running as Admin

@ghord
Copy link

ghord commented Oct 12, 2023

Yeah, for now it seems best solution is to to just implement in-app Drag&Drop yourself without using builtin apis.

@zhuxb711
Copy link
Contributor

After more than one year development, WinUI team still not resolve this issue.

@shelllet
Copy link

After more than one year development, WinUI team still not resolve this issue.

This is a very critical bug. Don’t the Microsoft team think so?

@conioh
Copy link

conioh commented Nov 7, 2023

Yeah, for now it seems best solution is to to just implement in-app Drag&Drop yourself without using builtin apis.

Sounds like the best solution is not to use Windows App SDK / WinUI 3 as long as that's the level of maturity and support.

@MetalMonkey-GSD
Copy link

MetalMonkey-GSD commented Dec 5, 2023

Our current application ships with SDK 1.3.230724000 and many of our customers suddenly have the same issue. Our application needs elevated mode. Strangely it never happened before the latest Windows updates. We didn't even change anything in our application.
Update: Same problem persists with SDK 1.4.231115000.

Same problem occurs even with the latest "WinUI 3 Gallery" app in elevated mode and latest SDK. It even sometimes crashes when switching between the pages.

This is a serious issue and must be addressed as soon as possible!

@martgoodall
Copy link

I support you MetalMonkey in saying this is a serious issue and is not being taken seriously. I don't even see an acknowledgement that the problem has been recreated, even though it takes 2 minutes to recreate.
Could someone at Microsoft acknowledge that this is a serious issue and provide an update as to the plan to fix it?
thx

@aquinn39
Copy link

aquinn39 commented Jun 11, 2024

This also seems to affect the TabView and it occurs in WinUI 2 with Xaml Islands as well - you can see in Notepad and Windows Terminal (microsoft/terminal#6661) they've just disabled the ability to reorder tabs when the app is running as administrator, otherwise the app will crash when you try to reorder tabs - quite disappointing that they've had to resort to that to address this issue since now you can't reorder tabs when running as admin. And this is in the latest release version of Windows 11 as well.

@zhuxb711
Copy link
Contributor

After two years, I have never seen WinUI team plan to fix this issue.

@yagdev
Copy link

yagdev commented Jun 24, 2024

After two years, I have never seen WinUI team plan to fix this issue.

A shame really as my app also depends on admin access for hardware sensors.
For now I just added a safeguard where I disable CanDrag if Admin access is detected.

@stevenbrix
Copy link
Contributor

i think the worst part about this is that it crashes even when dragging within your own application

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working feature proposal New feature proposal product-winui3 WinUI 3 issues team-Markup Issue for the Markup team
Projects
None yet
Development

No branches or pull requests