Screen display is slow even after executing Form.ShowDialog method
Currently, I am conducting a continuous test to execute a SQL statement in an application created in C #. If the continuous test is performed for about 3 to 4 hours, it will take about 5 seconds to display the screen by executing the Form.ShowDialog…
SaveFileDialog does not handle longpath format
Targeting core 3.1 on windows 10 Setting a Microsoft.Win32.SaveFileDialog.InitialDirectory = "\?\C:\" results in the error: System.ArgumentException: Value does not fall within the expected range. at at…
Is it necessary to have two TCP Socket per client
As I was learning WPF and MVVM, I developed a small Trading Server and 2 type of Clients in WPF. In that application I'd 2 Scoket per client on both Client and Server side, one for Receive and one for Send byte[]. In some places I read that TCP Socket is…
SVG to DataTemplate not working which as PathGeometry
I have 3 Country Flags in SVG , I need to Convert SVG to DataTemplate. Example : France Flag , this is Working <DataTemplate x:Key="France"> <Grid HorizontalAlignment="Stretch"> <Path…
How to debug in Visual Studio where there is a timespan feature specified
Hi I am writing a C# wpf app, and there are calls for timers in it and the timer has a timespan feature in it, for example. These timespans's are specified as TimeSpan.FromHours(1). How do I debug these lines to see if the method below it gets…
BluetoothLEDevice PairAsync intermittantly fails
Working on an application that connects to a bluetooth low energy device that requires an initial pairing before the device characteristics and services can be subscribed or read etc. Sometimes the pairing of the device fails, unfortunately, the result…
BLE 4.2 connection failing due to access denied
Hi, We are running into a connection issue on multiple windows 10 computers (regardless of the version) when attempting to connect (pairing/bonding/connecting) to a ble 4.2 device using our wpf application (the issue can also be reproduced with the…
ListBox with WrapPanel as ItemPanel does not scroll to top when contents are set
I have a ListBox with a WrapPanel as the ItemPanel. When the ItemsSource is set the ListBox does not go to the top. I have read lots of posts (none of which work) about all sorts of ways to do it. I try to use MVVM and none of the them use that. It…
WPF DefaultStyleKey vs DefaultStyleKeyProperty.OverrideMetadata
What is the difference between these static XXXXXXX() { DefaultStyleKeyProperty.OverrideMetadata(typeof(XXXXXXX), new System.Windows.FrameworkPropertyMetadata(typeof(XXXXXXX))); } and public XXXXXXX() { …
Click Once application fails to fully launch when certain other applications are running
Our click once application runs fine if everything else on the workstation is closed. When certain other applications, including Amazon Music and Visual Studio Code (when VS Code has updates available), are running the main window for our application…
C# Win Form Design - Form design bottom edge not coming properly in Laptop resolution
I am facing one more issue. bottom curve edge not coming properly in my laptop resolution. the same alignment will be working in desktop properly. but, when i am checking the form at my laptop then the bottom edge is not coming properly. when i…
[wpf] how can l output a bitmap form System.Windows.Controls.Image
This is my Code: <Grid> <Image x:Name="img" Source="xxx.png" Stretch="Fill"> **<Image.Clip> <PathGeometry> …
(WPF) Textbox problem when creating a spell check using hunspell
I am trying to create a spellcheck solution using Hunspell. I want to make it like the spell check function provided by MS. Richtextbox has already succeeded, but textbox fails to display red underlines in misspelled words. In other words, I want to know…
Replacing all ToolTips with a custom ToolTip in WPF
For example, let's say I have this element: <Button ToolTip="Click here!" /> Instead of the ToolTip being the default WPF ToolTip, can I define a style/template that will replace all default ToolTips with a custom one? Maybe…
Refresh Combobox Items list and seleceted item with unchanged bounded source/property
Hello, i have a project where i want to switch the language at runtime (german, english). I decided to use System.Globalization and ConverterCulture={x:Static sysglb:CultureInfo.CurrentUICulture}. In the following code snippets i extracted and abstracted…
Updating or Adding Only The Relevant Record of WPF DataGrid
Hi All, While going through a sample project in learning WPF Core as I attempted to work with setting up a DataGrid with Updating Buttons' Column on the Window, I found that with code pieces like the following, if I carried out any change, upon…
Issue with WPF application becoming unresponsive after plugging or unplugging a USB device supporting pen events
I've run across an issue on Windows 10 where WPF apps seem to become unresponsive when unplugging or plugging in a USB device that registers as an input device that can receive touch/stylus events. This can be seen by creating a basic WPF app in Visual…
Using MediaCapture from WPF Framework class assembly
I have an existing WPF application that needs to make use of the MediaCapture class. The idea is to put the image management in a class assembly so that the same code can easily be used across multiple applications. There are a couple of examples on how…
WPF C# DataGrid ComboBox Column not showing value after scrolling when inserting row and it's not visible
Hello, I have a WPF C# phone numbers application, where registries (people's data) are shown in a DataGrid. One of its columns is ComboBox type, and its items are one or more phone numbers, and it shows always the first of them. The issue comes when…
C# DataGridView Deleting All Columns
After some time, when using the DataGridView in C#, the Columns are all deleted when trying to re-arrange them. When adding a new column it gives an Error that the column is not a valid identifier.