Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7410873
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T06:17:59+00:00 2026-05-29T06:17:59+00:00

I have an application written using Prism 4.0. It has lots of Views which

  • 0

I have an application written using Prism 4.0. It has lots of Views which have different controls which bind to ViewModel properties (I don’t have Models in my app). Some of those controls visualize datetime and decimal values. In some places the string representations have correct format, but in some places they don’t. But if I represent those decimal and datetime properties as string properties and call ToString() methods on the underlying values, then their format will be correct. So CurrentThread.CurrentCulture of my ViewModel thread is correct. But the data binder’s or Prism’s or whatever code converts datetime and decimal values to strings thread culture seems to be incorrect, or maybe they are not using current culture at all. My debugging skills are not sufficient yet to go behind the curtains, but I think that magic happens here (stack trace):

    [Native to Managed Transition]  
    PresentationFramework.dll!MS.Internal.Data.PropertyPathWorker.GetValue(object item, int level)  
    PresentationFramework.dll!MS.Internal.Data.PropertyPathWorker.RawValue(int k)   
    PresentationFramework.dll!MS.Internal.Data.PropertyPathWorker.RawValue()    
    PresentationFramework.dll!MS.Internal.Data.ClrBindingWorker.RawValue()  
    PresentationFramework.dll!System.Windows.Data.BindingExpression.TransferValue(object newValue, bool isASubPropertyChange)   
    PresentationFramework.dll!System.Windows.Data.BindingExpression.ScheduleTransfer(bool isASubPropertyChange) 
    PresentationFramework.dll!MS.Internal.Data.ClrBindingWorker.NewValueAvailable(bool dependencySourcesChanged, bool initialValue, bool isASubPropertyChange)  
    PresentationFramework.dll!MS.Internal.Data.PropertyPathWorker.UpdateSourceValueState(int k, System.ComponentModel.ICollectionView collectionView, object newValue, bool isASubPropertyChange)   
    PresentationFramework.dll!MS.Internal.Data.ClrBindingWorker.OnSourcePropertyChanged(object o, string propName)  

Any ideas how to force WPF & Prism to use correct number and datetime format anywhere?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T06:18:00+00:00Added an answer on May 29, 2026 at 6:18 am

    Placing the following line of code in your startup code may fix the issue:

    FrameworkElement.LanguageProperty.OverrideMetadata(typeof(FrameworkElement), new FrameworkPropertyMetadata(XmlLanguage.GetLanguage(CultureInfo.CurrentCulture.IetfLanguageTag)));  
    

    This will set the LanguageProperty for all WPF controls to the current culture.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a WPF application that is written using MVVM Prism. It has a
I have web application written in java using Eclipse. It has just one servlet
I have a C# application of which some parts are written using WPF (which
I have an CMS application which is written using C#, and I should Save
I have a web application written using CherryPy, which is run locally on 127.0.0.1:4321
I have an application written in c++ using visual studio 2005. The application has
I have an application written in platform-independent C++ which has been primarily developed on
I have an application written using C++ Builder 5 that uses the TDocument class.
I have an application written using the M-V-VM approach. The data access is done
Here's my question. Right now I have a Linux server application (written using C++

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.