2016-02-09 00:06:13 +00:00
|
|
|
|
using System;
|
|
|
|
|
using System.Resources;
|
|
|
|
|
using System.Reflection;
|
|
|
|
|
using System.Globalization;
|
|
|
|
|
|
|
|
|
|
namespace TestProjectWithCultureSpecificResource
|
|
|
|
|
{
|
|
|
|
|
public class Program
|
|
|
|
|
{
|
2016-06-06 22:08:46 +00:00
|
|
|
|
// This method is consumed by load context tests
|
|
|
|
|
public static string GetMessage()
|
2016-02-09 00:06:13 +00:00
|
|
|
|
{
|
|
|
|
|
var rm = new ResourceManager(
|
|
|
|
|
"TestProjectWithCultureSpecificResource.Strings",
|
|
|
|
|
typeof(Program).GetTypeInfo().Assembly);
|
|
|
|
|
|
2016-06-06 22:08:46 +00:00
|
|
|
|
return rm.GetString("hello") + Environment.NewLine + rm.GetString("hello", new CultureInfo("fr"));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public static void Main(string[] args)
|
|
|
|
|
{
|
|
|
|
|
Console.WriteLine(GetMessage());
|
2016-02-09 00:06:13 +00:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|