Is there any way to have to tabcontrol take the size of the largest tab item (well, actually, the tabitem's content)?
Since the tabcontrol has no specific size assigned it should autosize: it does that correctly, but when you switch tabs it automatically resizes itself to the height (and width) of the contents of the currently selected ...
I have two text boxes, one for a billing address field and one for a shipping address field. When the user types something into the the billing address text box the shipping address text box gets the same value due to the following binding scenario:
<TextBox Name="txtBillingAddress" Text="{Binding BillingAddress, UpdateSourceTrigger=Pro...
I have a TreeView that creates all its items from databound ObservableCollections. I have a hierarchy of GameNode objects, each object has two ObservableCollections. One collections has EntityAttrib objects and the other have GameNode objects. You could say that the GameNode object represents folders and EntityAttrib represents files. To...
Hi!
I have a login form that contains a username textbox and a password box.
I want the ok button to be enabled only when both the fields contain a value.
I have a converter that check for all the strings if they're null or empty.
I placed a breakpoint on the first line of the Convert method, and it stops only when the MenuItem initial...
For the life of me, I can't seem to bind to my viewmodel using multibindings. All of the examples on the net bind to gui elements directly, but whenever I try with a viewmodel object exceptions are thrown.
My question is, how do I add a multibinding to several viewmodel objects in xaml?
I need to bind the IsEnabled property of a contex...
I am sorry I didn't know how to title my question any better, you name it if you got a good 1.
I have an entity Contact.
this person has navigation properties: Address, Phones (A collection of Phone).
They all implement a custom interface that exposes a property IsValid.
In the contact edito form I have an OK button, I want its IsEnab...
Hey
I have an XmlDataProvider that refers to an XML file and a specific node, and a TextBlock which it's Text property is bind to an element.
So far so good, everything works and I can see the element's value in the TextBlock.
What I'm trying to do is to forward that value into a method that will return me a string value that I have to...
Hi
for a single binding, we use:
<TextBlock>
<TextBlock.Text>
<MultiBinding StringFormat="{}{0}">
<Binding Path=EmployeeName/>
</MultiBinding>
</TextBlock.Text>
</TextBlock>
or a shorter syntax:
<TextBlock
Text="{MultiBinding StringFormat=\{0\}, Bindings={Binding Path=EmployeeName}}"/>
Now, if you have multibi...
I need to have a command handler for a ToggleButton that can take multiple parameters, namely the IsChecked property of said ToggleButton, along with a constant value, which could be a string, byte, int... doesn't matter.
I found this great question on SO and followed the answer's link and read up on MultiBinding and IMultiValueConverte...
I've written a MultiValueConverter which checks if a given list contains a given value and returns true if it does. I use it for binding to custom checkbox list. Now I'd like to write ConvertBack method so that if checkbox was checked, original value would be sent to the model. Is there a way to access values in ConvertBack method?
XAML...
Hi,
i have this case where there is a multibinding for ex,
textbox1 which value depend on textbox2 and textbox3 and the binding is two way,
all textbox applied the same validation rule for ex error if minus.
somehow if textbox1 got updated the textbox2 and textbox3 validation will fire.
but when either textbox2 or textbox3 updated, tex...
Hi everyone,
I hope I am not being silly asking this, but I am trying to design a graph viewer in WPF being a total newb in the framework; although I did come up with a couple of solutions to my problems, the one I'm most proud of... does not work where it should. What I'm trying to do is to place a node on the ItemsControl at a positio...
Hello, I need to implement MultiBindings in C# directly without using XAML, I know how to use the IMultiValueConverter in C#, but, how to do:
<MultiBinding Converter="{StaticResource sumConverter}">
<Binding ElementName="FirstSlider" Path="Value" />
<Binding ElementName="SecondSlider" Path="Value" />
<Binding ElementName="ThirdSli...
In WPF, I've three objects exposing the same DependencyProperty (let's say it's an integer). I want all three property values to remain synchronized, i.e. that whenever the int value changes in an object, this value is propagated to the two other objects. I think of multibinding to do the job, but I don't know how to detect which object ...
I am trying to develop an application that uses a number of images that are stored in a seperate remote file location. The file-paths to the UI elements are stored within the Application Settings. Although I understand how to access the images from Applications Settings using a MultiBinding and a value converter, I'm not sure how to inte...
I ask because it doesn't seem to work.
Assume we're binding to the following object:
public class HurrDurr
{
public string Hurr {get{return null;}}
public string Durr {get{return null;}}
}
Well, it would appear that if we used a MultiBinding against this the fallback value would be shown, right?
<TextBlock>
<TextBlock.Text> ...
Suppose I have this MultiBinding:
<MultiBinding Converter="{StaticResource FooBarConverter}>
<Binding Path="Foo" Converter="{StaticResource FooConverter}" />
<Binding Path="Bar" Converter="{StaticResource BarConverter}" />
</MultiBinding>
This doesn't seem to work: the values array passed to FooBarConverter contains DependencyProp...
Hi-
I'm trying to use a MultiBinding with a converter where the child elements also have a converter.
The XAML looks like so:
<TextBlock>
<TextBlock.Text>
<MultiBinding Converter="{StaticResource localizedMessageConverter}" ConverterParameter="{x:Static res:Resources.RecordsFound}" >
<Binding Converter="{StaticResource lo...
Is there a way to take this multibinding:
<TextBox.IsEnabled>
<MultiBinding Converter="{StaticResource LogicConverter}">
<Binding ElementName="prog0_used" Path="IsEnabled" />
<Binding ElementName="prog0_used" Path="IsChecked" />
</MultiBinding>
</TextBox.IsEnabled>
and put is all on one line, as in <TextBox IsE...
I would like to know if there is a way to connect to multiple resources:
Specifically I have the following problem
abstact class BaseClass
{
ObservableCollection<BaseClass>;
}
class GrandSonClass:BaseClass{}
class SonClass:BaseClass{}
class FatherClass:BaseClass
{
CollectionViewSource col = new CollectionViewSource ;
col.Sourc...