Click here to Skip to main content
15,886,823 members
Home / Discussions / WPF
   

WPF

 
QuestionGrid Dynamic Column and Row in run time in WPF MVVM Pin
sels198711-Sep-12 15:59
sels198711-Sep-12 15:59 
AnswerRe: Grid Dynamic Column and Row in run time in WPF MVVM Pin
Clifford Nelson12-Sep-12 13:39
Clifford Nelson12-Sep-12 13:39 
QuestionPopUp Window Open and close in WPF MVVM pattern Pin
sels19878-Sep-12 21:53
sels19878-Sep-12 21:53 
AnswerRe: PopUp Window Open and close in WPF MVVM pattern Pin
Mycroft Holmes9-Sep-12 14:25
professionalMycroft Holmes9-Sep-12 14:25 
AnswerRe: PopUp Window Open and close in WPF MVVM pattern Pin
Pete O'Hanlon10-Sep-12 5:03
mvePete O'Hanlon10-Sep-12 5:03 
AnswerRe: PopUp Window Open and close in WPF MVVM pattern Pin
Abhinav S10-Sep-12 16:14
Abhinav S10-Sep-12 16:14 
AnswerRe: PopUp Window Open and close in WPF MVVM pattern Pin
_Maxxx_29-Oct-12 17:30
professional_Maxxx_29-Oct-12 17:30 
QuestionTuple as a Binding Parameter Pin
Ahrimal6-Sep-12 22:11
Ahrimal6-Sep-12 22:11 
Hi there.

I have a control, that depending on its size and diferent parameters return me a value. Issue is that I need to do this in xalm and not in code, and do not know how to pass a tuple using xaml.

Now I have it by code:

C#
Binding dataBinding = new Binding();
                dataBinding.Source = this.ZoomMemoryArea.MemoryAreaData;
                dataBinding.UpdateSourceTrigger = UpdateSourceTrigger.PropertyChanged;
                dataBinding.Path = new PropertyPath("Size");
                dataBinding.Converter = new BlockingRectangleMemorySizeConverter();
                dataBinding.ConverterParameter = new Tuple<Canvas, IMemoryAreaData>(this.zoomCanvas, this.MemoryArea.MemoryAreaData);
                dataBinding.Mode = BindingMode.OneWayToSource;
                this.zoomControl.SetBinding(Control.WidthProperty, dataBinding);


And the ???? is what I really do not know how to do.
XML
<pre lang="xml"><ContentControl.Width>
    <Binding Mode="OneWayToSource" UpdateSourceTrigger="PropertyChanged"  Converter="{StaticResource memorySizeConverter} ConverterParameter=???? Path="MemoryAreaData.Size" Source="ZoomMemoryArea">
                </Binding></pre>


As for multiBinding, I can't use it as this is a OneWayToSource binding so I would not get more than one value.

Any sugestion would be much apreciated.

Regards
Forgot to add the converter

QuestionBinding to an XML list of attributes Pin
Jayme656-Sep-12 11:46
Jayme656-Sep-12 11:46 
AnswerRe: Binding to an XML list of attributes Pin
Pete O'Hanlon6-Sep-12 22:24
mvePete O'Hanlon6-Sep-12 22:24 
GeneralRe: Binding to an XML list of attributes Pin
Jayme657-Sep-12 6:11
Jayme657-Sep-12 6:11 
GeneralRe: Binding to an XML list of attributes Pin
Pete O'Hanlon7-Sep-12 6:52
mvePete O'Hanlon7-Sep-12 6:52 
GeneralRe: Binding to an XML list of attributes Pin
Jayme657-Sep-12 7:10
Jayme657-Sep-12 7:10 
GeneralRe: Binding to an XML list of attributes Pin
dbaseman7-Sep-12 21:06
dbaseman7-Sep-12 21:06 
GeneralRe: Binding to an XML list of attributes Pin
Jayme658-Sep-12 0:32
Jayme658-Sep-12 0:32 
GeneralRe: Binding to an XML list of attributes Pin
dbaseman8-Sep-12 10:08
dbaseman8-Sep-12 10:08 
GeneralRe: Binding to an XML list of attributes Pin
Jayme659-Sep-12 0:04
Jayme659-Sep-12 0:04 
GeneralRe: Binding to an XML list of attributes Pin
dbaseman9-Sep-12 16:18
dbaseman9-Sep-12 16:18 
QuestionHow to implement a gallery like the built-in gallery in Windows Phone Pin
small25-Sep-12 16:22
small25-Sep-12 16:22 
GeneralRe: How to implement a gallery like the built-in gallery in Windows Phone Pin
small29-Sep-12 15:19
small29-Sep-12 15:19 
QuestionSet background of TreeViewItem within HierarchicalDataTemplate with converter Pin
toengi19824-Sep-12 20:19
toengi19824-Sep-12 20:19 
AnswerRe: Set background of TreeViewItem within HierarchicalDataTemplate with converter Pin
Wayne Gaylard4-Sep-12 21:57
professionalWayne Gaylard4-Sep-12 21:57 
SuggestionRe: Set background of TreeViewItem within HierarchicalDataTemplate with converter Pin
toengi19824-Sep-12 22:03
toengi19824-Sep-12 22:03 
GeneralRe: Set background of TreeViewItem within HierarchicalDataTemplate with converter Pin
Wayne Gaylard4-Sep-12 22:11
professionalWayne Gaylard4-Sep-12 22:11 
SuggestionRe: Set background of TreeViewItem within HierarchicalDataTemplate with converter Pin
Mycroft Holmes5-Sep-12 12:52
professionalMycroft Holmes5-Sep-12 12:52 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.