Hello, sorry for any inconveniece caused.
Would like to ask about database or rather databinding
My Window look like this: http://i25.tinypic.com/a0x5kn.jpg
The browse button is look up the "My Network Place"
private void browseBtn_Click(object sender, RoutedEventArgs e)
{
FolderBrowserDialog dialog = new FolderBrowserDialog();
Ty...
Hi,
i have a problem with rotating a rectangle and place it on a canvas in a certain way. Here is what i try to achieve:
The big rectangle in the picture is my canvas. The smaller rectangle is my rectangle i want to rotate. When i rotate the rectangle (dotted rectangle), it gets clipped of course. To avoid this, i want to reposition ...
...any support for EDITORS?
Or do I have to open the solution in Blend for being able to do some editing in a design surface?
;)
...
I am working on a Surface application and I have a problem with multiple buttons getting pressed at the same time.
I have a menu control with a few buttons. Some of them are bound to Commands that make the hosting window fade out the menu control and run something else, while some are just hooked up to EventTriggers that fade through di...
I have a BookItemView class for data template of ListViewItem.
/// <summary>
/// Represent a class to keep every items view.
/// </summary>
public class BookItemView : ICloneable
{
/// <summary>
/// Create a new instance of BookItemView.
/// </summary>
public BookItemView()
{
...
I am trying to work out an example from ".NET Domain Driven Design with C#", which contains a code example where you can see declared some attributes of type DelegateCommand.
Now, I've tried googling it up, but I can't find its reference anywhere on MSDN (actually, I found this article, but not DelegateCommand's article itself).
Is the...
When button1 is clicked I want this sequence
RectangeA becomes visible
RectangeA opacity changed from 0 to 75% over lets say 3 seconds
ControlB becomes visible.
Steps 1 and 3 are easy with imperative code, but I'm assuming I need to learn how to use story boards to do step 2.
...
I'm novice in the GUI development, in particular with WPF, and don't know related patterns. So I want to ask you about a problem which arises from time to time and I'm not sure about the best solution for it.
Let we have three user controls A, B, C and control A include control B, control B include control C. Let control C has a button....
How to determine on over which node click was performed?
Treeview from silverlight toolkit.
In MouseRightButtonUp i need to get node:
private void treeView_MouseRightButtonUp(object sender, MouseButtonEventArgs e)
...
For my WPF application I'm using MVVM, and now I want to show a generated context menu when the user right-clicks on something.
Routing the right-click to some action was easy, but how do I show a contextmenu which items are generated by the ViewModel?
I don't even have an idea where to start to display a context menu, since I do not ha...
I have two Menu items in a wpf context,
I bind them with command, how do I hide context menu when both items are not available, I mean when both commands cannot be executed?
...
I want to get this.
Everything works so far, buttons act as filter and are bind to the grid control.
All i want is the icons and counter on the button.
Whats the correct way of implementing those?
<ToggleButton x:Name="IsErrorShown" Margin="4" Width="100" Content="{lex:LocText Errors, Assembly=Client}">
I have tried adding image li...
Hi All,
I want to scroll the listbox which is placed inside the srollviewer according to its selection.
ListBoxItem item = (ListBoxItem)(lbTrack.ItemContainerGenerator.ContainerFromItem(lbTrack.Items.CurrentItem));
// ListBoxItem item = (ListBoxItem)(lbTrack.ItemContainerGenerator.ContainerFromItem(lbTrack.SelectedItem));
...
I have a ListView. When I select a row I want that only one cell was selected not the whole row. How can I get this?
Here is my styles and templates.
<ListView x:Name="List"
ItemsSource="{Binding }"
ItemContainerStyle="{DynamicResource ListItemStyle}">
<ListView.View>
...
Hello,
I have a ListBox, and I need to set its ControlTemplate to a Virtualizing WrapPanel which is a class that extends VirtualizingPanel, using a style that looks like this:
<Style TargetType="{x:Type ListBox}" x:Key="PhotoListBoxStyle">
<Setter Property="Foreground" Value="White" />
<Setter Property="...
How do I change the color of the Fluent Ribbon UI backstage menu which is – by default – blue?
...
Hi,
I need to count the idle time of my WPF application (Idle time = when no keyboard input,mouse input (movement + clicks ) had occurred ).
So far I tried 2 approaches but none of them seem to be working:
Using the dispatcher to invoke a delegate each time it get a contextIdle priority, the problem is that binding and many other oper...
WPF defines most routed events in pairs, we have both Bubbling and tunneling events. I have seen people using Preview(tunneling) events for performing the operations instead of using the bubbling ones. As per my understanding preview events should only be used to perform some checks and/or handle the event if required.
Is it a good pra...
Hi,
My questions is the following: how can I test if an ICommand's Execute method was called on a mock object ?
I'm using the following code:
var mockOperandVM = new Mock<UCOperandViewModel> ();
mockOperandVM.Setup (x => x.EditCommand).Returns (new RelayCommand<String> (x => { }));
var toolbarTrayVM = new UCToolbarTrayViewModel (...
Hi,
I want to move a control along a path in WPF with a transformation. The movement should be smooth and the path is like a sine curve. Currently no idea how to start...
-sa
...