Skip to content

When PickContactAsync() returns, it prevents other windows to show #20383

@borrmann

Description

@borrmann

Description

I pick a contact. If there is more than one phone number, I want to ask the user which number he wants to pick.
When I open a new DisplayActionSheet, it doesn't open.
I tried to use the49 BottomSheet instead, which does open for a moment, but is then dismissed.

var contact = await Microsoft.Maui.ApplicationModel.Communication.Contacts.Default.PickContactAsync();
var phones = contact.Phones.Select(x => x.PhoneNumber).ToList();
string res = await Application.Current.MainPage.DisplayActionSheet("chosse a number", "cancel", null, [.. phones]);

Steps to Reproduce

  1. Pick a contact
  2. Show a DisplayActionSheet or another window
  3. The DisplayActionSheet does not show

Link to public reproduction project repository

https://github.com/borrmann/DialogClosesWindows

Version with bug

8.0.3

Is this a regression from previous behavior?

Yes, this used to work in .NET MAUI

Last version that worked well

7.0.49

Affected platforms

iOS

Affected platform versions

iOS 17, not sure about other

Did you find any workaround?

before opening another window, add a delay of 1000ms. Strangely, 500ms is not enough.
await Task.Delay(1000); string res = await Application.Current.MainPage.DisplayActionSheet("chosse a number", "cancel", null, [.. phones]);

Relevant log output

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-essentialsEssentials: Device, Display, Connectivity, Secure Storage, Sensors, App Infohas-workaroundi/regressionThis issue described a confirmed regression on a currently supported versionpartner/syncfusionIssues / PR's with Syncfusion collaborationplatform/ioss/triagedIssue has been revieweds/verifiedVerified / Reproducible Issue ready for Engineering Triaget/bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions