I have a static readonly variable storing a file path that I get from runtime. I want to load the spellcheck.customdictionaries uri from this static readonly variable, how do I do it? I have made it work with specifying the full path of the file in xaml:
<TextBox Name="txtNote"
Grid.Column="0"
AcceptsReturn="True"
MaxLines="2"
VerticalScrollBarVisibility="Auto"
Text="{Binding Path=Note,
ElementName=ucNoteEditor}"
TextWrapping="WrapWithOverflow" SpellCheck.IsEnabled="True" >
<SpellCheck.CustomDictionaries>
<sys:Uri>m:\test.lex</sys:Uri>
</SpellCheck.CustomDictionaries>
</TextBox>
I want to make it so that the Uri get it's value from a static variable at runtime. I want to do it at the xaml, not from code behind.