daily pastebin goal
29%
SHARE
TWEET

Untitled

a guest Jan 19th, 2019 65 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var rm = new ResourceManager("ProductXYZ.Localization.App_GlobalResources.Messages", Assembly.Load("ProductXYZ.Localization"));
  2. viewModel.Message = rm.GetString("SuccessfullySaveChanges", CultureInfo.CreateSpecificCulture(user.Language ?? CultureName));
  3.    
  4. protected void Application_PostAuthenticateRequest(object sender, EventArgs e)
  5. {
  6.     CultureInfo ci = CultureInfo.CreateSpecificCulture(HttpContext.Current.User.Language ?? CultureName);
  7.     Thread t = System.Threading.Thread.CurrentThread;
  8.     t.CurrentCulture = ci;
  9.     t.CurrentUICulture = ci;
  10. }
  11.    
  12. viewModel.Message = rm.GetString("SuccessfullySaveChanges", CultureInfo.CreateSpecificCulture(user.Language ?? CultureName));
  13.    
  14. viewModel.Message = rm.GetString("SuccessfullySaveChanges");
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top