23,179 questions with .NET-related tags

Sort by: Updated
0 answers

VS Go to error line in catch()

When an error occurs in a block that is inside a try{}catch{}, how can I go back to the line that produced it?

.NET
.NET
Microsoft Technologies based on the .NET software framework.
3,196 questions
asked 2024-03-05T02:42:45.32+00:00
zequion 91 Reputation points
edited the question 2024-03-05T06:05:40.9266667+00:00
Anna Xiu-MSFT 24,051 Reputation points Microsoft Vendor
0 answers

System.NullReferenceException at Microsoft.Maui.Platform.KeyboardAutoManagerScroll.AdjustPosition()

I'm working on a Maui plugin that sometimes presents some native iOS UI.  I'm seeing a crash at Microsoft.Maui.Platform.KeyboardAutoManagerScroll.AdjustPosition() when that UI is presented modally and a DidUITextBeginEditing notification is fired (by the…

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
2,629 questions
asked 2024-03-04T19:44:02.27+00:00
Frank Schmitt 0 Reputation points
commented 2024-03-05T06:04:30.86+00:00
Yonglun Liu (Shanghai Wicresoft Co,.Ltd.) 31,156 Reputation points Microsoft Vendor
0 answers

How to play an audio file in .NET MAUI

I want to play a sound on my mobile application (android and IOS) So I've Added the sound file under the “Resource/Raw” folder with BuildAction=MauiAsset and Added Nuget package "Plugin.Maui.Audio" and used below code to play the…

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
2,629 questions
asked 2024-03-01T08:04:45.89+00:00
Mane, PRASHANT GORAKH 76 Reputation points
commented 2024-03-05T06:02:52.97+00:00
Mane, PRASHANT GORAKH 76 Reputation points
1 answer

Maui - Using Timer in multi main page navigations

Hi, Here is my code: Did I used in correcy way ? Thanks in advance, private IDispatcherTimer _indicatorTimer; public MainPage(string navigateTo) { InitializeComponent(); currentContentViewHolder.Children.Clear(); if (navigateTo ==…

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
2,629 questions
asked 2024-03-03T10:46:21.53+00:00
דני שטרית 2,266 Reputation points
edited the question 2024-03-05T06:01:16.2266667+00:00
Leon Lu (Shanghai Wicresoft Co,.Ltd.) 64,576 Reputation points Microsoft Vendor
0 answers

I Saved C# Project form as a new name, now project is broken. How to fix it?

I have a C# project in Visual Studio Community 2022 with a single form for the interface. I made some changes to the form and wanted to save it as a different name so I could preserve the previous design. Now I cannot see the form in the designer, but…

Windows Forms
Windows Forms
A set of .NET Framework managed libraries for developing graphical user interfaces.
1,806 questions
Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
4,446 questions
asked 2024-03-05T02:56:24.25+00:00
Clay LaHatte 0 Reputation points
commented 2024-03-05T06:01:07.7733333+00:00
Olaf Helper 39,181 Reputation points
0 answers

Unable to parse TLS packet header

i just upgrade my xamarin project to maui and i have an httpclient error Unable to parse TLS packet header when i try to comunicate with my api HttpClient httpClient = new HttpClient(); response = await httpClient.SendAsync(msg, cts.Token); sendasync…

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
2,629 questions
asked 2024-03-04T09:38:23.7166667+00:00
commented 2024-03-05T05:59:52.5066667+00:00
Yonglun Liu (Shanghai Wicresoft Co,.Ltd.) 31,156 Reputation points Microsoft Vendor
0 answers

How to fix recent errors generated by switching to .net 8.0

I had an app that was compiling and running just fine. I endeavored to put a map on the Home Page and read something that suggested that I upgrade to .net 8.0. Well it's been a nightmare and I've lost weeks of productivity. I believe I have the map…

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
2,629 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
9,987 questions
asked 2024-03-04T23:09:32.5833333+00:00
StevenSquires-9060 21 Reputation points
commented 2024-03-05T05:54:29.3633333+00:00
Yonglun Liu (Shanghai Wicresoft Co,.Ltd.) 31,156 Reputation points Microsoft Vendor
0 answers

How to merge file with different extensions in C#

Merging Files having different extensions into one given file with .mrg extension

ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,027 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
9,987 questions
asked 2024-03-05T04:15:57.2933333+00:00
yashrajsinh gohil 0 Reputation points
edited the question 2024-03-05T05:48:25.4966667+00:00
Zhi Lv - MSFT 30,026 Reputation points Microsoft Vendor
0 answers

No Internet page change

I have a no internet page, and I check if the connection comes up again. public partial class App : Application { private readonly AppShell _appShell; private readonly NoInternetPage _noInternetPage; public App(AppShell appShell,…

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
2,629 questions
asked 2024-03-04T17:54:57.5566667+00:00
Eduardo Gomez 3,216 Reputation points
commented 2024-03-05T05:41:53.94+00:00
Yonglun Liu (Shanghai Wicresoft Co,.Ltd.) 31,156 Reputation points Microsoft Vendor
1 answer

Can not create folder in SharePoint. (Upgrade MS Graph SDK 5.36.0 -> 5.44.0 version)

I try to use below code to create folder in SharePoint. DriveItem driveItem; var driveItemAdd = new DriveItem() { Name = folder.Name, Folder = new Microsoft.Graph.Models.Folder() { OdataType = "microsoft.graph.folder" } }; …

SharePoint Server
SharePoint Server
A family of Microsoft on-premises document management and storage systems.
2,156 questions
.NET
.NET
Microsoft Technologies based on the .NET software framework.
3,196 questions
SharePoint
SharePoint
A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.
9,216 questions
asked 2024-03-01T09:55:11.3+00:00
Jackie Dinh 0 Reputation points
commented 2024-03-05T05:39:03.8666667+00:00
RaytheonXie_MSFT 29,126 Reputation points Microsoft Vendor
1 answer

.NET MAUI Package.appxmanifest always requires runFullTrust when I don't need it.

Hello, my question is related to .NET MAUI or maybe to WINUI 3 itself, by default all of those project templates sets runFullTrust capability, which I don't really need, I wanted to remove it, but I get compiler errors that I cannot remove it. Any tips…

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
2,629 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
9,987 questions
asked 2024-02-03T15:00:42.2166667+00:00
Jonathan Soderstorm 0 Reputation points
commented 2024-03-05T05:38:40.9766667+00:00
Yonglun Liu (Shanghai Wicresoft Co,.Ltd.) 31,156 Reputation points Microsoft Vendor
2 answers

Automated Certificate Installation in Android using MAUI within Microsoft MAUI Framework

How can I programmatically install a certificate on Android using MAUI within the Microsoft MAUI framework?

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
2,629 questions
asked 2024-02-02T06:34:27.5566667+00:00
Sarfaraz Sable 20 Reputation points
commented 2024-03-05T05:38:01.3866667+00:00
Yonglun Liu (Shanghai Wicresoft Co,.Ltd.) 31,156 Reputation points Microsoft Vendor
1 answer

C# Spans example is confusing.

Hi, I was reading up on Spans and I didn't understand the following example; struct MutableStruct { public int Value; } ... Span<MutableStruct> spanOfStructs = new MutableStruct[1]; spanOfStructs[0].Value = 42; Assert.Equal(42,…

.NET
.NET
Microsoft Technologies based on the .NET software framework.
3,196 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
9,987 questions
asked 2024-03-05T03:07:22.5233333+00:00
answered 2024-03-05T05:37:20.22+00:00
Jiachen Li-MSFT 24,751 Reputation points Microsoft Vendor
1 answer

is the .net android performance better than .net maui android?

If I create .net android is the performance better than .net maui android? ignore the startup time the performance difference big or equal?

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
2,629 questions
asked 2024-02-05T16:00:01.42+00:00
mc 3,481 Reputation points
commented 2024-03-05T05:36:47.5833333+00:00
Yonglun Liu (Shanghai Wicresoft Co,.Ltd.) 31,156 Reputation points Microsoft Vendor
1 answer

How to handle System.Runtime.InteropServices.COMException error in Plugin.BLE ?

"I'm running the below function every second, and it stops when the connection is lost. The error, a System.Runtime.InteropServices.COMException with HResult=0x80004004, on the line var data = await…

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
2,629 questions
asked 2024-02-05T18:18:52.4366667+00:00
Sowndarrajan Vijayaragavan 290 Reputation points
commented 2024-03-05T05:36:02.7366667+00:00
Yonglun Liu (Shanghai Wicresoft Co,.Ltd.) 31,156 Reputation points Microsoft Vendor
1 answer

can not tap on swipeView items?

in SwipeView there is Grid and I add TapGestureRecognizer but when I tap on it nothin happen. when I use SwipeView I can not click it ? in SwipeItem?

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
2,629 questions
asked 2024-02-06T16:02:57.39+00:00
mc 3,481 Reputation points
commented 2024-03-05T05:35:50.21+00:00
Yonglun Liu (Shanghai Wicresoft Co,.Ltd.) 31,156 Reputation points Microsoft Vendor
1 answer

rethinking user flow

I am coding my user flow but this time I am going to dynamically create the menu. So, in my shell, I have two pages. Startup Page Login Page The startup page is responsible for checking for the token and redirect the user. public class…

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
2,629 questions
asked 2024-03-02T15:31:31.4966667+00:00
Eduardo Gomez 3,216 Reputation points
answered 2024-03-05T05:33:40.0833333+00:00
Yonglun Liu (Shanghai Wicresoft Co,.Ltd.) 31,156 Reputation points Microsoft Vendor
0 answers

Could not load type 'Microsoft.AspNetCore.Mvc.MvcJsonOptions' from assembly 'Microsoft.AspNetCore.Mvc.Formatters.Json while updgrading .net core 2.2 to 8.0 or 3.1

Hi All While upgrading .Net core 2.2 project to .Net 8.0. I am getting below error. I am using upgrade assistant from Visual studio 2022. (Same issue if I am upgrading to 3.2 version) Application startup exception: System.TypeLoadException: Could not…

.NET
.NET
Microsoft Technologies based on the .NET software framework.
3,196 questions
ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,027 questions
asked 2024-03-05T00:58:47.3933333+00:00
Manoj Pruthi 0 Reputation points
commented 2024-03-05T05:17:38.9733333+00:00
Ping Ni-MSFT 1,365 Reputation points Microsoft Vendor
1 answer

How Remove DatePicker underline in .NET MAUI

In .NET MAUI, I am using a DatePicker to display a date on a page. However, on Android, it is showing an underline below it. I want to hide this underline. I have written the following code to achieve this, but it's not working. Could you please help me…

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
2,629 questions
asked 2024-03-04T07:11:22.7533333+00:00
Bhuwan 516 Reputation points
edited an answer 2024-03-05T05:16:45.0666667+00:00
Leon Lu (Shanghai Wicresoft Co,.Ltd.) 64,576 Reputation points Microsoft Vendor
1 answer One of the answers was accepted by the question author.

Issue with Pre-selection

I need to preselect the list if it has only one item , i tried the one suggested in the MAUI official docs but it never seemed to work for me . I tried by manually setting the following in the constructor of the code behind of the…

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
2,629 questions
asked 2024-02-15T10:54:06.42+00:00
Manickam, Suraj 160 Reputation points
commented 2024-03-05T05:02:32.3433333+00:00
Manickam, Suraj 160 Reputation points