Hello experts,
I'm looking for some input for a challenge that I'm currently facing.
I have built a custom WIF STS which I use to identify users who want to call some WCF services that my system offers. The WCF services use a custom authorization manager that determines whether or not the caller has the required claims to invoke a given...
Hello
I have the following code:
<UserControl x:Class="TestApp.View.ViewAlarmLog"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:Custom="http://schemas.microsoft.com/wpf/2008/toolkit"
xm...
Hello, i have a lot of some WPF windows. On them i write some code, which binds UI controls and data, something like this:
public class AddressWindow
{
public string AddressID { get; set; }
public string Addr1 { get; set; }
public string Addr2 { get; set; }
public string ZIP { get; set; }
...
In my SilverLight application, I have a property in my ViewModel called 'vmProperty' and a list called 'dgSource'.
I bind my dgSource to the datagrid as ItemsSource at which point each datagrid row's datacontext changes to each item in dgSource. One of the columns, say a checkbox column, needs to bind to vmProperty. But since the ViewM...
I am trying to produce a list of servers for browsing on a network such that it produces a tree view which looks like this:
-Local Server
- Endpoint 1
- Endpoint 2
-Remote
- <Double-click to add a server...>
- Remote Server 1
- Endpoint 1
- Endpoint 2
- Remote Server 2
- Endpoint 1
- Endpoint 2
My ViewModel looks like...
So I've seen that a Navigation Service exists in WPF for maintaining a flow through an application. I'm not really in the market for the back and forward type functionality. I'm just looking for a good way to switch between Views when a button on a particular view is pressed. I'm using MVVM, so I'm not sure if I can let the App.xaml.c...
I currently have an app (in Silverlight), using mv-vm, that has an interface to add/edit/remove various entries to a database. A good analogy would be a page for ordering a car with many checkboxes and comboboxes for whatever features you wanted the car to include.
My app has many of these UI elements (even including TreeViews with Tree...
Hi guys, I'm trying to bind focus for my control to a property on the view model, like this:
public class Focus
{
public static readonly DependencyProperty HasFocusProperty = DependencyProperty.RegisterAttached("HasFocus",
t...
I'm using WPF with the Model-View-ViewModel pattern. Thus, my code behind files (.xaml.cs) are all empty, except for the constructor with a call to InitializeComponent. Thus, for every .xaml file I have a matching, useless, .xaml.cs file.
I swear I read somewhere that if the code behind file is empty except for the constructor, there ...
Guess we have simple model, e.g. let it be a Person { Name, Age }.
Now we want to display a list of persons.
Persons are read-only
We don't need to edit them
We don't need any additional stuff like presentation properties, etc.
Now question is if it is a good practice do not create PersonViewModel class that will probably be ...
tl;dr: I want detail views to appear in 2 columns if 2 items are selected, and to span 2 columns if only 1 item is selected.
I have a DockPanel with 2 ListBoxes docked on the left and a 2-column Grid on the right.
When an item is selected in listBox1, I display a details view in Column 0 of the Grid.
When an item is selected in lis...
I'm trying to learn the MVVM pattern. The main problem I'm having is learning where I should be declaring, creating and binding command objects.
2 examples:
I have a main form that acts like a switch board or main menu. Selct button 1 and View 1 is displayed, Select button 2 and view 2 is displayed. Great. Now I want to go back to...
hi
I am trying to populate a treeview using mvvm but the tree does not display any data.
I have a Employee list which is a property in my vm which contains he employee data.
the xaml is as follows.
<Style TargetType="{x:Type TreeViewItem}">
<Setter Property="FontWeight" Value="Norma...
I have a WPF application based on PRISM that utilizes the MVVM pattern.
I have noticed that occasionally my view models, views and everything connected to them will hang around long after their intended lifespan.
One leak involved subscribing to CollectionChanged on a collection belonging to an injected service, another involved not ca...
I have some reusable ContentControl, which acts as a pseudo-modal popup inside another view.
It is always there and only its visibility makes it appear or disappear.
When instantiated, within the ContentControl there will be a custom ContentTemplate, bound to some ViewModel and representing the content of the "modal popup".
<Dialogs:Mod...
Hi, how i can use Application Navigation Framework (SL) with MVVM, I'm use MVVM Light Toolkit..
Thanks.
...
I'm using M-V-VM with dialog boxes. The process I'm using for creating dialogs is as follows:
A ViewModel command wishes to open a dialog.
It creates the ViewModel for the dialog (we'll call it DialogViewModel).
It then passes the ViewModel off to a DialogProvider to create the actual View. This makes my dialog boxes testable, as the...
Hello everyone.
I'm developing WPF applications using MVVM pattern. I have ViewModel with code like this:
public bool EditModeEnabled
{
get { return _EditModeEnabled; }
set
{
_ModeEditModeEnabled = value;
OnPropertyChanged("EditModeEnabled");
OnPropertyChanged("CommentTextBoxVisibility");
}
}
O...
I'm trying to get sorting to work with a WPF Toolkit DataGrid. My DataGrid's rows are instances of view models. The row's view model exposes a view model for each column. Each column is data templated to a different user control. This is what my DataGrid's column declarations look like:
<tk:DataGrid.Columns>
<tk:DataGridTemplateColu...
I'm trying to get to grips with MVVM and so I've read a bunch of articles - most focus on the View -> ViewModel relationship and there's general agreement about what's what. The ViewModel -> Model relationship and what constitutes the Model gets less focus and there's disagreement. I'm confused and would like some help. For example, t...