Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
370
Passing multiple parameters to the Converter
posted

I have to pass two parameters to my converter i.e a string and an xmldocument , is it possible to pass multiparameters through xaml. I Shall be exposing the parameters as dependency properties. As a work around have already tried using multivalueConverters but it doesn't work well for my scenerio. PLease provide your valuable comments... :-)

Thanks much.

Parents
  • 69686
    Verified Answer
    posted

    Hello,

    How do you want to pass these parameters to the constructor. Is the XML document a string as well (its name).

    Does the RelayObject approach (as in Silverlight) works in your scenario?

    <x:Array Type="{x:Type sys:Object}" x:Key="array">

    <sys:String>Parameter 1</sys:String>

     <sys:String>Parameter 2</sys:String>

    </x:Array>

    ...

    <Binding Converter="{StaticResource conv}" ConverterParameter="{StaticResource array}"/>

    Alex.

Reply Children
No Data