Hi,
I am trying to make a 2-way binding of a class property.
public class MyClass{
public MyField AField1{get;set;};
public MyField AField2{get;set;};
}
public class MyField{
public string Value {get; set}
}
MyClass _class = MyClass();
_dv.DataSource = _class;
Databinding text object displays MyField class name instead of Value Prop...
So here is the XAML that I have:
<ItemsControl ItemsSource="{Binding Path=Groups}" ItemTemplateSelector="{Binding RelativeSource={RelativeSource AncestorType=Window}, Path=ListTemplateSelector}"/>
Here is my ListTemplateSelector class:
public class ListTemplateSelector : DataTemplateSelector {
public DataTemplate GroupTemplate { get;...
I have a list of object and want to bind for display purposes to a list of custom controls.
XAML code:
<Pages:MyItemsControl ItemsSource="{Binding SquadFieldPlayers}">
<Pages:MyItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<Canvas Height="180" Width...
I have a binding to an unknown source. All I have is the binding. I have no other way of looking at the bound object. I need to figure out the Type for the bound object, even if the value is null (this is where my problem is).
I was evaluating the binding by binding to an object and then using the object as a way to get the Type, but I ...
Im desperately trying to remove subversion bindings in my netbeans project but I cant work out how to.
I've tried to copy the files to another directory but the original svn bindings stays intact from the original source. Its hopelessly annoying!
Please help!
Thanks!
...
I have a class:
Public Class TestClass
Implements INotifyPropertyChanged
Public Event PropertyChanged As PropertyChangedEventHandler Implements INotifyPropertyChanged.PropertyChanged
Public Sub OnNotifyChanged(ByVal pName As String)
RaiseEvent PropertyChanged(Me, New PropertyChangedEventArgs(pName))
End Sub
P...
Hello,
Today I noticed a strange behavior regarding binding the header of a DataGridColumn to the ViewModel.
The following binding works perfectly (name of the DataGrid is MyGrid):
<DataGridTextColumn Binding="{Binding Name}" Width="*" CanUserReorder="False" CanUserResize="False" IsReadOnly="True">
<Da...
Q: Why does my custom TextBox UserControl using a MultiBinding and IMultiValueConverter gets its Convert() method called only once (during instanciation) ??
I have defined a UserControl that requires a MultiBinding and a IMultiValueConverter in order to change its behavior/presentation upon 2 indenpendant DependencyProperty.
<proj:MyCo...
So I am having an issue with the TreeView. If I build a tree view statically, every node in the tree is selectable in that when I click on it, it highlights itself blue, indicating that node is selected.
<TreeView
Grid.Column="0"
Grid.Row="2"
MinHeight="100"
MinWidth="100"
BorderBrush="White"
DataContext="{Bind...
How to bound 2 variables in C++ one with other so when one changes changes another?
for example I created Int A and Int B bound one to another and than when I change A one using some function another one will automatically change to new value of A.
I am intrested in version for C++ .net 4th version.
...
I am currently injecting an iframe and binding a keyevent both to the document and the iframe.
Can I select both the iFrame and the document in one row?
notice the iframe must have .contents() after the selector
// wait for iframe to load
$('iframe#iframe').load(function() {
// event bind to document
$(document).bind('keydown'...
hi,
i have 2 NSMutableArray with same type. i want to add second nsmutablearray to first one.
NSMutableArray *tmpArray1 (10 objects in it)
NSMutableArray *tmpArray2 (10 objects in it)
if i use [tmpArray1 addobject:tmparray2]; tmpArray1's count goes to 11.
but i want to append tmparray2 to firstone. count must be 20.
thanks...
...
Gentlemen,
I have a button bounded on Validation.HasError property of a textblock. The textblock has a validation rule that checks the value entered by user. The purpose of the binding is that the button should be disabled if the user enters a wrong data.
The problem is that the ValidationRule executes AFTER the binding. So when the u...
hello! i have next situation:
I have own controller ( myController : NSObjectController ) an overridden method -(id)valueForKeyPath in it for bind my attributes. And I have some method like -(BOOL)canRemove;
I want to button 'Enable' to -(BOOL)canRemove; but can't.
It must like bind button 'Enable' to canAdd of NSController.
I sink ...
How do I bind the isEnabled property of play, pause, rewind & forward buttons - for a MediaElement?
I can do this in code of course on MediaOpened & MediaClosed, using a shared dependancy property, but I just wondered if I can bind all the buttons (maybe with a converter) directly to a property of the MediaElement? I thought HasVideo l...
Hello.
I'm developing a Windows Phome application. I have the following ListBox on a page:
<ListBox Margin="10,10,8,8" x:Name="WallList">
<ListBox.ItemsPanel>
<ItemsPanelTemplate>
<StackPanel />
</ItemsPanelTemplate>
</ListBox.ItemsPanel>
<ListBox.ItemTemplate>
<DataTemplate>
<Grid x:Name="ListBoxItemLayou...
I have tried to do it myself--asking for help on specific functions, but the more I think about the possibilities, the more lost I get. I have some software (quantum chemistry packages). That reads input files and generates output files that are basically clumps of data of the form:
Energy:[many spaces]6.3432
H 5
O 33 OHO 32
And weird st...
I am building an app where we are pulling messages off of MSMQ. The idea is to then take that message find a handler for it and process the message.
The method that is doing the retrieval and kicking off the processing looks like this
private void DoWork(object state)
{
var mq = MessageQueue.Exists(QueueName)
? new...
Hi, if I have an object say called MyObject, which has a property called MyChild, which itself has a property called Name. How can I get the value of that Name property if all I have is a binding path (i.e. "MyChild.Name"), and a reference to MyObject?
MyObject
-MyChild
-Name
...
I have a control in my XAML bound to a property with a style.
<TextBox x:Name="txtCapAmount" Text="{Binding Path=CapAmount}" Style="{DynamicResource AmountTextBoxStyle}" />
In the style I'd like to use the Binding from the control but am not sure how to set it
<Style x:Key="AmountTextBoxStyle" TargetType="{x:Type TextBox}">
<E...