Microsoft Q&A

.NET

20,734 questions

Microsoft Technologies based on the .NET software framework.

Browse all .NET tags

20,734 questions with .NET-related tags

Sort by: Updated
0 answers

How to protect Net.Core server from malicious content uploads by users?

Hi! I have a website where on certain pages the user can (through checks in the controller method): To save (upload to server) text in text fields and to CKEditor. To save (upload to server) images (.jpg) to website through CKEditor and through …

ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
3,585 questions
asked 2023-10-01T15:31:24.0033333+00:00
Volk Volk 301 Reputation points
commented 2023-10-02T10:17:36.2633333+00:00
Volk Volk 301 Reputation points
1 answer

How to check for null column in a DataRow

I'm using DataTables in 4.7.2, and I have defined a table with 2 columns, Start_Date and End_Date. If the 2nd column has a null value, how can I check for that? Right now I've gotten this far, which abends at runtime: // foreach (DataRow eachrow in…

.NET
.NET
Microsoft Technologies based on the .NET software framework.
2,068 questions
asked 2023-09-26T00:26:22.24+00:00
Coreysan 1,366 Reputation points
commented 2023-10-02T10:17:01.3333333+00:00
Jiale Xue - MSFT 11,336 Reputation points Microsoft Vendor
2 answers

EF Core: Map multiple c# classes to DB table

Hello, I have a DB table named JobPosting with 60 columns. I'd like to have 2 c# entities JobPostingFull & JobPostingLite which both reference the JobPosting table. The JobPostingFull class has all columns from the DB, the JobPostingLite class has…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
591 questions
asked 2023-09-30T14:36:07.7+00:00
Satish Cherian 0 Reputation points
commented 2023-10-02T10:06:12.71+00:00
AgaveJoe 685 Reputation points
0 answers

"Failed to get document because the client is offline" error in Xamarin.Forms project

Here is my code of App.xaml.cs file of a Xamarin.Forms project: public partial class App : Application { public App() { CrossFirebaseCrashlytics.Current.HandleUncaughtException(); InitializeComponent(); …

Xamarin
Xamarin
A Microsoft open-source app platform for building Android and iOS apps with .NET and C#.
5,160 questions
asked 2023-10-01T17:36:29.6766667+00:00
Costas Athan 21 Reputation points
edited a comment 2023-10-02T09:46:29.1666667+00:00
Costas Athan 21 Reputation points
1 answer

Creating a list with two different tables

I have following two tables Employee and file Path Employee - employeeId is primary key with Identity specification EmployeeId FirstName lastName 1 Mario Gonazales 2 Mario2 Gonazales2 3 …

ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
3,585 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,026 questions
asked 2023-10-02T06:09:20.51+00:00
Anjali Agarwal 1,061 Reputation points
answered 2023-10-02T09:34:23.6+00:00
Miguel Fernández Corral 0 Reputation points
1 answer

Display value of DropDownList SelectedItem on a label

Hello, I have been trying to show the value of DropDownList selecteditem in a label but all efforts could not yield desired result. I have a table Data as follows: IdFruits colors1Apple Red2Banana …

.NET
.NET
Microsoft Technologies based on the .NET software framework.
2,068 questions
ASP.NET
ASP.NET
A set of technologies in the .NET Framework for building web applications and XML web services.
1,640 questions
ASP.NET Web Forms
ASP.NET Web Forms
A part of the ASP.NET web application framework that can be used to create ASP.NET web applications.
620 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,026 questions
asked 2023-10-02T00:25:37.77+00:00
Donald Symmons 2,026 Reputation points
edited a comment 2023-10-02T09:29:27.0433333+00:00
Lan Huang-MSFT 17,956 Reputation points Microsoft Vendor
0 answers

Three material Design TextBoxes inside one MaterialDesignFloatingHintTexbox in WPF

I have a MaterialDesignFloatingHintTextBox which displays a "Date of Birth" hint to my users when it is empty. Here is what I want to implement: the TextBox to display three TextBoxes to the user when clicked in like this, so that my users…

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,482 questions
Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
3,817 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,026 questions
XAML
XAML
A language based on Extensible Markup Language (XML) that enables developers to specify a hierarchy of objects with a set of properties and logic.
693 questions
asked 2023-10-02T08:44:28.02+00:00
Mesh Ka 140 Reputation points
commented 2023-10-02T09:23:59.7433333+00:00
Hui Liu-MSFT 21,611 Reputation points Microsoft Vendor
0 answers

Maui mobile app using Signalr is encoding hub name in ConnectionData parameter on iOS 17

We have a mobile app in production built using Maui. The server running the api is it connecting to uses .net framework. There are issues connecting to signalR from iOS17 devices. From debug we can see the following: iOS 17 device sets the connectionData…

ASP.NET
ASP.NET
A set of technologies in the .NET Framework for building web applications and XML web services.
1,640 questions
.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
1,875 questions
asked 2023-09-27T11:39:11.9033333+00:00
T_TDSi 0 Reputation points
commented 2023-10-02T09:13:22.5266667+00:00
Wenyan Zhang (Shanghai Wicresoft Co,.Ltd.) 22,571 Reputation points Microsoft Vendor
1 answer

HttpListener used on Xamarin.IOS app. "Safari cant open the page because it couldn't connect to the server" error only on iOS 17 devices.

Our project uses the latest Xamarin and our app has a function that creates a HTTP server to store a html and config file, and we use SfSafariViewController to view the contents on the html file. However, after the release of iOS17, this function does…

Xamarin
Xamarin
A Microsoft open-source app platform for building Android and iOS apps with .NET and C#.
5,160 questions
asked 2023-09-20T06:21:25.29+00:00
ZNXJH 0 Reputation points
edited a comment 2023-10-02T09:11:01.59+00:00
Wenyan Zhang (Shanghai Wicresoft Co,.Ltd.) 22,571 Reputation points Microsoft Vendor
0 answers

how to remove realm database used in swift iOS in .NET MAUI?

Hello, I rebuild iOS app using .NET MAUI. There was data stored in realm database in iOS app. In MAUI, i want to remove it because it's no longer needed. Is there any way to do that? Thanks

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
1,875 questions
asked 2023-10-02T03:18:00.0066667+00:00
Nam Pham 71 Reputation points
edited the question 2023-10-02T09:08:10.97+00:00
Nam Pham 71 Reputation points
0 answers

Is there a way to automate adding the FullText Index to an Entity Framework migration

Hi all; Yes I can add the script to the Migration.Up() everytime I revise my model. But that is fundamentally no different from having a CreateIndexes.sql that I just run in SSMS after creating a DB. Is there some way to declare the full text indexes in…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
591 questions
SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
11,008 questions
asked 2023-10-01T21:18:20.5333333+00:00
David Thielen 1,426 Reputation points
commented 2023-10-02T09:03:42.7233333+00:00
Hui Liu-MSFT 21,611 Reputation points Microsoft Vendor
1 answer

How rendering handling concurrency in razor page from API response?

Hi, I'm following up on all the discussions I've had about handling concurrency errors. 1 - I would like to know if it is possible to handle concurrency errors in a context where I have a DataGrid in edition mode on a line? 2 - I have defined a put…

Blazor
Blazor
A free and open-source web framework that enables developers to create web apps using C# and HTML being developed by Microsoft.
1,112 questions
asked 2023-09-29T16:15:02.6566667+00:00
sblb 1,141 Reputation points
commented 2023-10-02T08:34:35.8033333+00:00
sblb 1,141 Reputation points
1 answer One of the answers was accepted by the question author.

Maui- app.cs write in constructor http call

Hi, I need to write http call asynchronously and i have only constructor their. Is not allowed to make asynchronous call in constructor? Thanks,

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
1,875 questions
asked 2023-10-01T06:25:22.0666667+00:00
דני שטרית 1,261 Reputation points
accepted 2023-10-02T08:31:28.9133333+00:00
דני שטרית 1,261 Reputation points
2 answers

LINQ and VB 2015 : Select Distinct in Sub-List of Objects...

Hi, this is a simple example about my task. I have a List of Objects, let's say a group of Persons and each Person has a Property which is a List of other type of Objects, let's say Colors. I'd like to get a Distinct List of all Colors kept by all…

.NET
.NET
Microsoft Technologies based on the .NET software framework.
2,068 questions
VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,321 questions
asked 2023-09-28T15:16:16.5533333+00:00
Marco Gregori 41 Reputation points
answered 2023-10-02T08:15:57.6133333+00:00
Marco Gregori 41 Reputation points
1 answer

getting the data from two different tables in a list

I have following two tables Employee and file Path Employee - employeeId is primary key with Identity specification EmployeeId FirstName lastName 1 Mario Gonazales 2 Mario2 Gonazales2 3 …

ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
3,585 questions
asked 2023-10-02T05:58:07.0766667+00:00
Anjali Agarwal 1,061 Reputation points
answered 2023-10-02T08:14:50.8866667+00:00
JasonPan - MSFT 2,691 Reputation points Microsoft Vendor
2 answers

Archive for Publishing not creating archive file

Hi Visual Studio Mac. MAUI app builds fine however Archive for Publishing does not create an archive file without any apparent error message. Checked under XCode->Organize->Window as well just to be sure. What can I do to fix this issue and get the…

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
1,875 questions
asked 2023-09-09T19:02:03.33+00:00
-- -- 841 Reputation points
answered 2023-10-02T07:56:10.32+00:00
Wenyan Zhang (Shanghai Wicresoft Co,.Ltd.) 22,571 Reputation points Microsoft Vendor
0 answers

MAUI extensions not available on visual studio 2022

I have Visual Studio v 17.7.4 and Visual Studio Preview v 17.8.0 and have recently installed the MAUI suite.  I am not given the option to create multi-platform apps as I assume I would on VS or VSP. I have gone through previous iterations of the…

Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
3,817 questions
.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
1,875 questions
asked 2023-09-17T23:15:46.5933333+00:00
Reabetswe Marumane Mogoswane 0 Reputation points
commented 2023-10-02T07:45:21.76+00:00
Leon Lu (Shanghai Wicresoft Co,.Ltd.) 54,166 Reputation points Microsoft Vendor
0 answers

Failed integrity metadata check for Blazor application (NET7)

0 I have a project in NET7 and Blazor hosted in an ASP.NET Core web application. The website is hosted by a service provider. When I deploy the application on the server in a hosting provider, I check the application with different browsers. The…

Blazor
Blazor
A free and open-source web framework that enables developers to create web apps using C# and HTML being developed by Microsoft.
1,112 questions
asked 2023-10-02T07:40:28.0466667+00:00
Enrico Rossini 96 Reputation points
edited the question 2023-10-02T07:41:37.7133333+00:00
Enrico Rossini 96 Reputation points
1 answer

How do I get the FreeTextTable.Rank via Entity Framework

Hi all; I'm able to get a list of records using FreeTextTable in Entity Framework as follows: var EventsSqlWhere = $"SELECT top 200 * FROM FreeTextTable(Events, *, {0}, 200) as t INNER JOIN Events u on u.Id = t.[KEY] ORDER BY t.[RANK]…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
591 questions
SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
11,008 questions
asked 2023-10-01T21:17:12.57+00:00
David Thielen 1,426 Reputation points
edited an answer 2023-10-02T07:39:20.0633333+00:00
Hui Liu-MSFT 21,611 Reputation points Microsoft Vendor
1 answer

Push notification on MAUI application using FCM

I am trying to implement push notification on my MAUI application using FCM. I follow this blog and I did everything as per the blog. They suggest to install only 2 NuGet packages, Plugin.Firebase and Plugin.Firebase.Crashlytics. (I installed it by…

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
1,875 questions
asked 2023-09-29T10:06:12.68+00:00
Sreejith Sreenivasan 406 Reputation points
answered 2023-10-02T07:36:48.3166667+00:00
Wenyan Zhang (Shanghai Wicresoft Co,.Ltd.) 22,571 Reputation points Microsoft Vendor