24,571 questions with .NET-related tags

Sort by: Updated
1 answer

Grouping DataGrid based on two Entity Framework tables

Hi All. The Form1 has DataGrid populated from EF table Table1. From Form1 I call Form2 that also has DataGrid with multiple selected items and populated from EF Table2 which is related to Table1. When I selected items in Form2 and click save button…

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,697 questions
asked 2020-09-21T17:45:43.167+00:00
zleug 61 Reputation points
answered 2020-09-22T14:46:09.037+00:00
zleug 61 Reputation points
1 answer One of the answers was accepted by the question author.

[UWP to WPF][C#] How to know whether bluetooth is on or off?

I want to know whether bluetooth is on or off in Windows 10. I found microsoft.sdk.contract package in nuget to use Windows 10 API including bluetooth-related methods. I tried to get 'Radio' instance using 'GetRadioAsync()' but it always throws…

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,697 questions
asked 2020-09-22T08:49:36.3+00:00
Joon 101 Reputation points
accepted 2020-09-22T10:01:37.763+00:00
Joon 101 Reputation points
1 answer

Create an Usercontrol

Hi I want an usercontrol like fontdialog, printdialog,notifyicon. That the user can set properties but not anything on design time form. Thanks

Windows Forms
Windows Forms
A set of .NET Framework managed libraries for developing graphical user interfaces.
1,865 questions
asked 2020-09-21T06:36:20.203+00:00
Kodeeswaran Duraisamy 161 Reputation points
answered 2020-09-22T07:02:48.733+00:00
Daniel Zhang-MSFT 9,621 Reputation points
1 answer One of the answers was accepted by the question author.

How to assign a hex color?

Hi Peter + Daisy, How to replace "Orange" with "#FFBF72FF" on line 5? Thanks. namespace WpfApp2.general_pages { class Pages_ViewModel : ICommand, INotifyPropertyChanged { public Color Tb3BackgroundColor { get; set; }…

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,697 questions
asked 2020-09-21T00:04:16.477+00:00
jennyliu835 221 Reputation points
commented 2020-09-22T05:07:53.7+00:00
jennyliu835 221 Reputation points
1 answer One of the answers was accepted by the question author.

missing Arc control in VS2019 Blend

I can't find Arc in assets. Visual Studio 2017 have it but 2019 not? How to bring Arc in to VS2019?

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,697 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,775 questions
asked 2020-09-21T13:34:52.553+00:00
Code Wanderer 396 Reputation points
accepted 2020-09-21T13:43:09.457+00:00
Code Wanderer 396 Reputation points
1 answer One of the answers was accepted by the question author.

Migrate windows form to MVVM pattern

Hi Team, using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Forms; namespace Matrix { public…

Windows Forms
Windows Forms
A set of .NET Framework managed libraries for developing graphical user interfaces.
1,865 questions
asked 2020-09-18T07:50:29.577+00:00
Srikant S 46 Reputation points
accepted 2020-09-21T09:30:43.02+00:00
Srikant S 46 Reputation points
1 answer

The forms are cut for me using high resolution on WinForm

I got a new laptop with very high resolution. I increased the size text, apps and other to 150% i work on WinForm program using Visual-Studio 2019. All the forms in my program are cut and everything goes wrong on the screen. i try this: …

Windows Forms
Windows Forms
A set of .NET Framework managed libraries for developing graphical user interfaces.
1,865 questions
asked 2020-09-18T15:07:33.7+00:00
GMS 1 Reputation point
answered 2020-09-21T08:18:22.273+00:00
Daniel Zhang-MSFT 9,621 Reputation points
1 answer

how create popup info to dispaly related data

Hi All. I have DataGrid that has context menu to call other form for add related data to selected item. Now I would like to create popup DataGrid in mouseover event on selected DataGrid item to display data that related to it. That gives information…

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,697 questions
asked 2020-09-16T18:29:05.507+00:00
zleug 61 Reputation points
commented 2020-09-21T07:47:25.58+00:00
DaisyTian-1203 11,616 Reputation points
2 answers

Capturing selection change / click inside WPF ListView / MVVM

Hi, I am trying to get the selection change inside a WPF ListView using Interaction.Triggers. I have only included just the basic XAML for now. But I am getting error in XAML as well as in code. XAML : The name interaction does not exist in namepace…

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,697 questions
asked 2020-09-20T12:25:43.187+00:00
winprofessional 41 Reputation points
answered 2020-09-21T03:09:12.147+00:00
DaisyTian-1203 11,616 Reputation points
2 answers

C# How to find out if a form is running

Hi, folks. I have a form application in C# (I use Visual Studio) that has two items in a menu. Both of them show the same form, but with different data. They access different tables in the database. If the user clicks in one of the menu items, the form…

Windows Forms
Windows Forms
A set of .NET Framework managed libraries for developing graphical user interfaces.
1,865 questions
asked 2020-09-17T01:00:21.713+00:00
Ismael Oliveira 1 Reputation point
commented 2020-09-21T02:47:01.587+00:00
Daniel Zhang-MSFT 9,621 Reputation points
1 answer

Putting a space in a WPF application name

I have created a WPF project named "MyApplication" because if you put a space it creates a weird namespace. However, I want my executable to be "My Application". Where can I make this happen and will changing it from…

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,697 questions
asked 2020-09-15T20:08:58.277+00:00
n0kx 1 Reputation point
commented 2020-09-21T01:39:23.723+00:00
DaisyTian-1203 11,616 Reputation points
1 answer

How do I make validation rules work with two controls, Part 2 of 2

(Part 1 is here: https://learn.microsoft.com/en-us/answers/questions/94723/how-do-i-make-validation-rules-work-with-two-contr.html) I'm not sure this will help, but here's the code to the validation rule class I've defined: using System; using…

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,697 questions
asked 2020-09-14T18:00:16.117+00:00
Rod At Work 866 Reputation points
answered 2020-09-21T01:25:44.787+00:00
DaisyTian-1203 11,616 Reputation points
1 answer

Winform Project and remote debugging

I have a winform project which i publish a centralize folder and user install application from that folder. so when i update any functionality and give publish then user gets update when they run their application. Please tell me how could i connect my…

Windows Forms
Windows Forms
A set of .NET Framework managed libraries for developing graphical user interfaces.
1,865 questions
asked 2020-09-18T17:14:49.18+00:00
Sudip Bhatt 2,271 Reputation points
answered 2020-09-18T18:07:14.69+00:00
David Lowndes 4,711 Reputation points
0 answers

How do I make validation rules work with two controls, Part 1 of 2

I've got a textbox that's within a border. The idea I'm trying to do is validate that the data entered by the user. I've done this with other controls (a DatePicker control and another textbox) but in those cases it wasn't validation, it was other things…

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,697 questions
asked 2020-09-14T17:57:32.193+00:00
Rod At Work 866 Reputation points
commented 2020-09-18T15:11:10.063+00:00
Rod At Work 866 Reputation points
1 answer One of the answers was accepted by the question author.

WPF Checkbox Control change size

Hello, I want to change checkbox size. who can help me? thanks XAML: <CheckBox x:Name="CheckAllBtn" Content="ALL" Canvas.Left="13" Canvas.Top="182" FontSize="36" Width="109"/>

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,697 questions
asked 2020-09-17T06:59:36.503+00:00
929Free 281 Reputation points
commented 2020-09-17T07:57:11.027+00:00
DaisyTian-1203 11,616 Reputation points
3 answers One of the answers was accepted by the question author.

WPF C# Desktop App - Build date from the application

Hello, private void MainWindow_Loaded(object sender, RoutedEventArgs e) { CurrentViewModel = (ViewModel)(this.Resources["vm"]); CurrentViewModel.InitFromMainWindow(); this.Title = "Setting…

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,697 questions
asked 2020-09-15T14:32:16.763+00:00
Markus Freitag 3,786 Reputation points
accepted 2020-09-17T05:46:15.383+00:00
Markus Freitag 3,786 Reputation points
1 answer One of the answers was accepted by the question author.

C# Version - increase the last number

Hello, How can I have the compile number counted up and output at each compile? Like this V1.0.0.000001 Next Like this V1.0.0.000002 Next Like this V1.0.0.000003

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,697 questions
asked 2020-09-16T07:46:04.97+00:00
Markus Freitag 3,786 Reputation points
accepted 2020-09-17T05:45:11.213+00:00
Markus Freitag 3,786 Reputation points
0 answers

Hosting WCF service in a mixed Iaas and Saas scenario

Hello, I currently have a WCF backend in a Windows service exposed via net.pipe for an ASP.NET web application, on premise. I would like to move to Azure. is it possible to install the WCF service on one or more servers (Iaas), expose the WCF services…

.NET
.NET
Microsoft Technologies based on the .NET software framework.
3,535 questions
asked 2020-09-16T13:24:17.933+00:00
Roberto Garavaglia 21 Reputation points
commented 2020-09-17T02:04:53.157+00:00
Peng Ding-MSFT 91 Reputation points
1 answer One of the answers was accepted by the question author.

How to group procedures and reuse - ViewModel

Hi Peter, How to group procedures on line 4, 5 and 6 into one method and reuse it at its original place (line 4, or 5 or 6 ) and on line 26. Thanks class Pages_ViewModel : ICommand, INotifyPropertyChanged { public Color Tb3BackgroundColor {…

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,697 questions
asked 2020-09-15T17:26:21.81+00:00
jennyliu835 221 Reputation points
commented 2020-09-16T22:32:51.333+00:00
jennyliu835 221 Reputation points
2 answers

Why am getting a CS0103 error on GetValue/SetValue, but in another class it doesn't raise that error?

I'm trying to define a DependencyProperty in a viewmodel class. Here's what I've got: public static readonly DependencyProperty SolutionIDProperty = DependencyProperty.Register("SolutionID", typeof(long), typeof(SolutionViewModel)); public…

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,697 questions
asked 2020-09-14T16:56:38.75+00:00
Rod At Work 866 Reputation points
answered 2020-09-16T08:08:47.383+00:00
DaisyTian-1203 11,616 Reputation points