Hi,
I'm trying to create something like a MDI tabbed Interface so I have a navigation pane (a Listbox) on the left, and a ContentPresenter on the right.
I have a ShellViewModel that has a BindableCollection on it called AvailAbleScreens and I managed successfully to bind to that list with a ListViews DataTemplate:
<ListView x:Name="Av...
Hello,
I'm building a simple UserControl, DoubleDatePicker, which defines a DependencyProperty, SelectedDate :
DoubleDatePicker.xaml :
<UserControl x:Class="TestWpfDoubleDatePicker.DoubleDatePicker"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:toolkit="h...
Hi all,
I've got a BindingSource with only 1 object as the DataSource.
I bind on some values on the datasource. That works perfectly.
BUT.
When I do:
bindingSource.DataSource = new Foo () { Bar = "..."; }
this is not reflected through the UI.
is there a way to force an update?
I tried resetbindings on the controls that bind to...
I'm attempting to implement a progress bar with a textbox on top that also displays the progress %. However the percentage is fractional. Is it possible to round a value returned in the dataset via the binding or does it have to be done via the code behind?
<ProgressBar Grid.Row="2" Grid.ColumnSpan="2" Height="25" HorizontalAlignment=...
Hi,
i have generated a Linq to Sql class which looks like this.
so i have 3 querys which gets my data.
private IQueryable<Gesellschaft> loadedGesellschaft;
private IQueryable<Anschrift> loadedGesellschaftAnschrift;
private IQueryable<Email> loadedGesellschaftEmail;
private lgDataContext completeGesellschaft;
private void Button_Cl...
I have static class that has a bunch of static properties. When I try to bind the property to a BindingSource (in the UI), I can pick the static class as the DataSource, however, when I drop down the DataMember combo, there is nothing there.
Can I use a static property of a static class as a DataMember of a BindingSource?
I should men...
Hi all,
I guess I'm a bit stuck on the mechanism of WPF DataBinding. Up to now I've thought of it as this : Any target of a DataBinding has to be a DependencyProperty.Keeping that in mind, I designed a very simple button-based UserControl like the following (boiled down to the most necessary parts):
XAML
<Button x:Class="MyNamespace.I...
Hi,
I have a Datagroup with a custom item renderer the momment I bind it to XML from an http service it stops working.
My XML:
<SDLIST>
<chartlist>
<reportname>FACTORY STATUS</reportname>
<reportimage>file:/D:/Work/RapidReport/Images/Charts/Vertical-Linear-Gauges.png</reportimage>
</chartlist>
<chartlist>
<reportname>FACTO...
I have a ListBox bound to a CollectionView which again is bound to a property on a viewmodel.
<ListBox ItemsSource="{Binding Source={StaticResource pumpCurvesViewSource}, ValidatesOnDataErrors=true}" />
Now, the viewmodel implements IDataErrorInfo, but the validation of the property on the viewmodel is never triggered. If I skip the C...
I'm trying to confirm a binding behavior I believe I have observed, but I'm not exactly sure of.
My original understanding was that a UserControl was sort of a black box, where if you wanted to share information back and forth with the controls contained within, you had to (1) use the DataContext or (2) define them on the surface of the...
I haven't really done a two way binding project before, so this might be a simple question.
I have an business object with all the right interfaces (INotifyPropertyChanged, etc...). I bound a Int32 property called CPP to a textbox named txtCPP via a BindingSource. The rules state that if CPP is less than 0, the text box should be blan...
I'm working with Spring MVC and I'd like it to bind a a persistent object from the database, but I cannot figure out how I can set my code to make a call to the DB before binding. For example, I'm trying to update a "BenefitType" object to the database, however, I want it to get the object fromthe database, not create a new one so I do n...
I am implementing a barebones framework in JavaScript that just provides data-binding between objects. The data-binding can either be one-way or two-way, and potentially have multiple objects bound on some property. There are several data-binding solutions available for various languages and I am trying to get a good idea of the best of ...
I have a CLR instance property, a static PropertyPath which points to the instance property and a xaml binding which uses the static PropertyPath directly like so:
NB: GetPropertyPath is simply a method which returns the propertypath based on the given linq expression from the member name.
public static PropertyPath MyPropertyPat...
I have a ListBox with Foo objects, and based on some events I disable/enable the ListBoxItems in the ListBox. Using the ListBox.Items property I find Foo objects, and from what I've understood I need to use the following function to get the ListBoxItem container for the Foo. Correct?
foreach (var item in Items)
{
var lbi = ItemCont...
I have a collection ObservableCollection<Foo>, and I want to bind this to a property in a custom controller of type ObservableCollection<object>. However, the bound value never reaches the PropertyCallback, and is hence never set.
Is there a clever way to achieve this binding? I could create an IValueConverter that converts from Observ...
My requirement is as follows, I am calling a procedure and I'm populating a DataTable. Assume that the procedure is returning emp_id, emp_name, designation and status. When I use DataGridView1.DataSource = <Name of the DataTable>, I get all the columns populated into the DataGridView. How can I display only selected columns in the DataGr...
Hi,
I'd like to visualize XML data with the WPF TreeView control. The treeview displays all elements of the XML data in hierarchical order. Below the treeview is a ListBox containing TextBoxes for editing the name, the value of the element and all its attributes.
I have figured out how to display the XML data in the treeview. But I don...
I have a bindinglist. i am using a textbox to show its items
WithEvents xBind As New BindingList(Of Emp)
I added items this way
xBind.Add(New emp("alpha0", "B"))
xBind.Add(New emp("alpha1", "B"))
xBind.Add(New emp("alpha2", "B"))
xBind.Add(New emp("alpha3", "B"))
I am binding the first property to a textbox
TextBox1.DataBindings.A...
For a radgrid, in the GridNeedDataSource Event, the eventargs include:
RebindReason
IsFromDetailTable
This useful for determining whether the rebinding is caused by Parent or Child grid.
What if I have a 3-tier grid?
Parent > Child > Grandchild
This boolean parameter will only tell me whether or not the grid raising the event was the ...