wpf

How I Retrieve Data from SQL Server Database hosted on a Web Server in my desktop application?

断了今生、忘了曾经 提交于 2021-02-20 02:55:55
问题 I have SQL Server Database which is present on some web server.I made a WPF or Windows form Desktop application using C# .Net.I want to retrieve data from sql server database in my desktop application as per end user requirements on its own local PC.Give me best way and best solution regarding security and accessing data. 回答1: You have 2 options. 1. Write the business logic layer which resides on the web-server and communicates with DB to serve the required data based on requests coming from

How I Retrieve Data from SQL Server Database hosted on a Web Server in my desktop application?

给你一囗甜甜゛ 提交于 2021-02-20 02:55:06
问题 I have SQL Server Database which is present on some web server.I made a WPF or Windows form Desktop application using C# .Net.I want to retrieve data from sql server database in my desktop application as per end user requirements on its own local PC.Give me best way and best solution regarding security and accessing data. 回答1: You have 2 options. 1. Write the business logic layer which resides on the web-server and communicates with DB to serve the required data based on requests coming from

WPF C# - How do I avoid grouping taskbar icons?

核能气质少年 提交于 2021-02-19 15:26:02
问题 When I create a new window using .Show() , it shows the new window, however my icons are grouped like below: I don't want that. I want the icons to be separate because I want my users to easily open the window that they want instead of having to click it, view the list of open windows, then choosing which one they want every time. I don't want to use .ShowDialog() because I need the users to be able to focus on either window no matter the state of the other. Meaning, both windows will need to

WPF C# - How do I avoid grouping taskbar icons?

倾然丶 夕夏残阳落幕 提交于 2021-02-19 15:23:12
问题 When I create a new window using .Show() , it shows the new window, however my icons are grouped like below: I don't want that. I want the icons to be separate because I want my users to easily open the window that they want instead of having to click it, view the list of open windows, then choosing which one they want every time. I don't want to use .ShowDialog() because I need the users to be able to focus on either window no matter the state of the other. Meaning, both windows will need to

Cannot populate a WPF DataGrid using Python

南楼画角 提交于 2021-02-19 12:52:54
问题 I have a problem binding data to a WPF DataGrid using Python.NET The code is shown below, and I've tried three different approaches to binding data - each fails and the error message is included as a comment in the code below If I do not attempt to add data, the datagarid displays correctly with headers. But I'm unable to populate the grid with any data. Any help will be gratefully received!!! Doug import clr #.NET references import System import System.Windows.Controls as WPFControls import

Cannot populate a WPF DataGrid using Python

99封情书 提交于 2021-02-19 12:50:54
问题 I have a problem binding data to a WPF DataGrid using Python.NET The code is shown below, and I've tried three different approaches to binding data - each fails and the error message is included as a comment in the code below If I do not attempt to add data, the datagarid displays correctly with headers. But I'm unable to populate the grid with any data. Any help will be gratefully received!!! Doug import clr #.NET references import System import System.Windows.Controls as WPFControls import

Cannot populate a WPF DataGrid using Python

我只是一个虾纸丫 提交于 2021-02-19 12:50:53
问题 I have a problem binding data to a WPF DataGrid using Python.NET The code is shown below, and I've tried three different approaches to binding data - each fails and the error message is included as a comment in the code below If I do not attempt to add data, the datagarid displays correctly with headers. But I'm unable to populate the grid with any data. Any help will be gratefully received!!! Doug import clr #.NET references import System import System.Windows.Controls as WPFControls import

WPF Application: Wake computer from sleep or hibernation

和自甴很熟 提交于 2021-02-19 08:43:12
问题 The last day i've tried to make this work: Wake up my computer from sleep or hibernation, using a WPF application. Nothing i've tried worked. So far I've tried the most popular examples on the net.. For example: [DllImport("kernel32.dll")] public static extern SafeWaitHandle CreateWaitableTimer(IntPtr lpTimerAttributes, bool bManualReset, string lpTimerName); [DllImport("kernel32.dll", SetLastError = true)] [return: MarshalAs(UnmanagedType.Bool)] public static extern bool SetWaitableTimer

WPF: Make simple highlight on mouse

隐身守侯 提交于 2021-02-19 08:33:10
问题 I try to write code to make simple highlight on mouse I make a full window and making it transparent it's working but i can't click through i searched for solution i find This Solution but the eclipse doesn't move and whole events doesn't work XMAL Code: <Window x:Class="ChangeMousePosition.MainWindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Title="MainWindow" Topmost="True" AllowsTransparency="True" WindowStyle=

How to disable expanding/collapsing of tree items in WPF TreeView on double-click

浪子不回头ぞ 提交于 2021-02-19 08:09:06
问题 How can I disable tree items collapsing/expanding when I double-click on tree item? I still would like to do this by clicking on toggle button, but not when I double-click on item. This is XAML I have: <TreeView Grid.Column="0" Grid.Row="0" ItemsSource="{Binding Categories}" helpers:TreeViewHelper.SelectedItem="{Binding SelectedCategory, Mode=TwoWay}" > <TreeView.ItemContainerStyle> <Style TargetType="{x:Type TreeViewItem}"> <Setter Property="IsExpanded" Value="True"/> </Style> </TreeView