Blazor Maui .Net 6 /Request Again Permission (Deny Mode) In Blazor Page
See original GitHub issueHi, I have the same problem, but my problem is different.
I want to get my request Permissin from the user in Blazor pages (For example. FetchData.razor
), for example with a snackbar or some other Message way, But when the user rejects my permission request => Deny, I can not request again, please help !!
@Eilon
if (ActivityCompat.ShouldShowRequestPermissionRationale(this, Manifest.Permission.AccessFineLocation))
{
// Provide an additional rationale to the user if the permission was not granted
// and the user would benefit from additional context for the use of the permission.
// For example if the user has previously denied the permission.
var requiredPermissions = new String[] { Manifest.Permission.AccessFineLocation };
Snackbar.Make(Test,
"plz",
Snackbar.LengthIndefinite)
.SetAction("ok",
new Action<View>(delegate (View obj) {
ActivityCompat.RequestPermissions(this, requiredPermissions, 1);
}
)
).Show();
}
else
{
ActivityCompat.RequestPermissions(this, new String[] { Manifest.Permission.Camera }, REQUEST_LOCATION);
}
_Originally posted by @masoodafar-web in https://github.com/dotnet/maui/issues/3694#issuecomment-1014880727_
Issue Analytics
- State:
- Created 2 years ago
- Comments:22 (9 by maintainers)
Top Results From Across the Web
Permissions - .NET MAUI
Learn how to use the .NET MAUI Permissions class, to check and request permissions. This class is in the Microsoft.Maui.
Read more >xamarin - .Net Maui: StorageWrite permission stops ...
The permission request dialog will show and the picture saved successfully after I granted the permission. Share.
Read more >Check and Request Permissions in .NET MAUI - YouTube
Will you please do a full Bluetooth instructional video? I'm not a former Xamarin person, so setting up for native calls is new...
Read more >NET MAUI Basics: Start Up, Permissions, App Data (W/ Blazor)
Net Maui with Blazor video that you should watch in order to get started ... Set Location in Emulator 17:00 Request and Check...
Read more >How to Build and Secure Web Applications with Blazor
Learn how to build client-side Web apps using Blazor and how to secure them with Auth0 authentication and authorization features.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
for android after update 6.0.300-rc.2.5513+sha.8a017cf73-azdo.6048189 not able to access camera from html javascript. previously it was working by inherit class BlazorWebViewHandler and override WebChromeClient GetWebChromeClient()
But after update GetWebChromeClient gets compile error.
Since there is a separate issue for the other problem https://github.com/dotnet/maui/issues/6610 you are facing.
I’m going to close this issue as we already provided a working solution to the original problem.