We're starting a new project and deciding to use Winforms or WPF.
I've read some of the other SO posts, and realize that WPF has some advantages in the data-binding and appearance areas, but also has a steep learning curve and fairly immature tools and controls.
We would like to better understand if Microsoft is planning on stopping ...
When using a ListCollectionView, how do I move focus to the newly created record?
My declarations are
Public WithEvents Data As PersonList = PersonList.GetList()
Private MyView As New ListCollectionView(Data)
Private WithEvents _Person As Person
The code I use to insert a person is
_Person = New Person("AAAA", 100)
Data.Inser...
I have a dialog that pops up over the main screen (it's actually a user control that appears on the page as per the application demo from Billy Hollis) in my application that has data from the main screen to be edited. The main screen is read only.
The problem I have is that when I change the data in the dialog, the data on the main scr...
I have a problem regarding StartUp Url in WPF. I have a LoginView.xaml and MainWindow.xaml. I want at first to open LoginView after that automatically to be opened MainWindow.
App.xaml
<Application x:Class="XXX.App"
xmlns="....."
Startup="App_Startup"
>
App.xaml.cs
/
// <summary>
/// Called when the app...
When I try to compile the following code, I get the error 'Visibility' member is not valid because it does not have a qualifying type name.
What do I have to change so that I can make the TextBlock disappear when Status=off?
XAML:
<Window x:Class="TestTrigger123345.Window1"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/prese...
How to store the DataView of a listview to a System.Data.DataView?
...
This XAML makes text fade in when it appears.
I would like to put this functionality into a Style.
However, but what do I put in for the "TargetName" since the style doesn't know which element is going to be using it?
How can I convert this fade-in effect to a style?
<TextBlock Name="Message" Text="This is a test.">
<TextBlock.Trig...
Why does the following code get the runtime error Members of the Triggers collection must be of type EventTrigger?
But the EventTrigger element doesn't have a Binding property.
So how do I change the color of the TextBlock based on the DataContext Property?
XAML:
<Window x:Class="TestTrigger123345.Window1"
xmlns="http://schemas.m...
Is it possible to synchronize videos running in a WPF application across two or more computers? Synchronizing several videos running on the same machine seems to work well using the ParallelTimeline class and MediaTimelines for each video instance, but I haven’t figure out a way to do this across different computers, which if possible, w...
I have a Canvas which I would need to animate the RenderTransform property of. The start and end matrices will be abitrary, so I can't pre write the storyboard in XAML, so I'm trying to do it in code, I can't find any example of how to do this, below is my best try which does not work (it compiles and runs, but the rendertransform does ...
Does anyone know how to get the correct mouse position during a drag-and-drop operation in WPF. I've used Mouse.GetPosition() but the returned value is incorrect.
Thanks.
...
I give up, how do I cast this?
class AmountIsTooHighConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
{
//int amount = (int)value;
//int amount = (int)(string)value;
//int amount = (int)(value.ToString);
/...
I want to create a UI sequence where the user clicks a button and it pops up a small panel below it with a button and a textbox and maybe a small list of items.
The dialog is non-modal and more importantly, it just goes away when you click somewhere else in the main window.
For example, when you click the 'Favorites' Star icon in Intern...
Is there a framework that supports UnitTesting of WPF applications. It should not be to difficult to establishe, because I don't want that writing the tests takes ten times longer than implementing a small feature.
...
Do you know any good WPF control library (even commercial) and what experiences have you made with them?
...
How to disable datagrid cell edit?
...
I have a WPF tabcontrol with 3 tabs. On the top of the first page is a scrollviewer with a couple buttons which make up a menu of common tasks (save, load etc). I would like this scroll viewer to appear at the top of every tab. Is it possible to do this without simply copying and pasting the code to every tab?
...
I have a toolkit:DataGrid (from Codeplex).
It is starting to have many different styles:
one for switching it on and off based on a variable in the ViewModel
one for visual styling
one for some other triggers, etc.
Do all of these need to be in one big style, is that the only way to do it? Or can I have multiple styles and attach th...
I've inherited a C# .net WPF application from a now ex-employee and am having some difficulties running the application. It all builds fine without a single error or warning, but before the GUI appears I get an error:
An unhandled exception of type 'System.FormatException' occurred in mscorlib.dll
Additional information: Corrupt...
I have a list view that has a column databound to a list.Count see below:
<ListView.View>
<GridView>
<GridViewColumn Header="Contacts" DisplayMemberBinding="{Binding Path=Contacts.Count}"/>
<GridViewColumn Header="Notes" DisplayMemberBinding="{Binding Path=Notes.Count}"/>
</GridView>
</ListView.View>
The List i...