A text block which will show the volume name, colon, Directory character seperator.
In english culture it will show C:\
and in japanese culture it will show C:'Yen'
View.XAML file:
<TextBlock Text="{Binding VolumeNameString, Mode=OneWay}"/>
ViewModel.cs file:
public string VolumeName
{
get
{
return m_volumeName;
}
private set
{
if (m_volumeName != value)
{
m_volumeName = value;
OnPropertyChanged("VolumeNameString");
}
}
}
public string VolumeNameString
{
get
{
return (this.VolumeName + ":" + System.IO.Path.DirectorySeparatorChar.ToString(CultureInfo.CurrentCulture));
}
}
The issue is in japanese culture, it is still showing C:\
and not showing C:'Yen'
.
'Yen' is Yen symbol here. I tried with Japanese OS but the issue is still there.
Am I doing anything wrong here? Application is created on .NET 3.5.