cultureinfo Questions

5

Is there a way to find the days that constitute a weekend or workweek based on different cultures using the .NET framework? For example, some Muslim countries have a workweek from Sunday through Th...
Metrify asked 7/1, 2010 at 8:35

2

Solved

I found one interesting thing in CultureInfo class. I was writting an app in ASP.NET and I was using Thread.CurrentThread.CurrentCulture to get the current selected language and: Thread.CurrentThr...
Increate asked 15/10, 2013 at 10:2

1

Solved

Is it possible to create a custom culture without registering it in Windows? Every solution and documentation refers to CultureAndRegionInfoBuilder class with calling Register after new culture has...
Keeler asked 25/3, 2013 at 4:12

5

Solved

I want to show pound sign and the format 0.00 i.e £45.00, £4.10 . I am using the following statement: <td style="text-align:center"><%# Convert.ToString(Convert.ToSingle(Eval("tourOurPric...
Sportscast asked 12/8, 2009 at 13:14

3

Solved

I was wondering if it was a good practice to instantiate a CultureInfo object repeatdedly in a loop process (few thousand times). This object is required in many Date and String methods to force a ...
Polynomial asked 19/9, 2013 at 18:58

4

Solved

I'm working with an API that returns some information about audio streams in a file, more specifically the audio language in its three-letter ISO name (ISO 639-2) representation. I would like to p...
Valora asked 23/3, 2012 at 14:36

2

My application supports multi language including English ,Chinese, Hindi Language. I need to display the currency symbol in the textbox based on the culture selected. How can this be done?
Illumine asked 12/7, 2013 at 13:11

1

Solved

This is probably a simple question, and I'm sure there's a way to do it with string.format(), NumberFormatInfo, CultureInfo or some combination of them, but I need to display large numeric values w...
Biota asked 9/5, 2013 at 16:32

4

Solved

I am changing the application culture based on the selected currency. eg. _culture = new CultureInfo("en-US"); _culture = new CultureInfo("fr-FR"); Is there any place where I can get all the n...
Auricula asked 12/4, 2013 at 10:10

3

Solved

I think I understand the CultureInfo usage. If I do simple : const int a = 5; string b = a.ToString(); is it equal to : const int a = 5; string b = a.ToString(CultureInfo.InvariantCulture); ...
Courtund asked 4/4, 2013 at 18:42

3

Solved

I have run into an issue that is probably due to my mis-understanding of how the DateTime.ToShortTimeString() method works. When formatting time strings with this function, I was assuming that it w...
Sweat asked 18/8, 2009 at 7:2

2

Solved

I try to remove the thousand separator so I'm experimenting some code, but it throws and exception. I tried with Convert.ToDouble, Convert.ToDecimal etc. it says: Convert.ToDouble("1.234,45") ...
Hungerford asked 21/3, 2013 at 11:1

3

Solved

First of all, this is not a duplicate of: Quickest way to enumerate the alphabet Because I need to get all the characters of the alphabet OF AN ARBITRARY (variable) LANGUAGE, and that in the corre...
Tapley asked 15/4, 2011 at 12:25

2

Solved

I have a curiosity related to culture change in MVC. I tried in 2 ways, but apparently I was wrong somewhere. In my Web.config I have : <globalization uiCulture="auto" culture="auto" /> ...
Morava asked 27/2, 2013 at 9:31

2

Solved

C# offers a way to get the current date by DateTime.Now. But the problem is my server is on US and I get the US time when I use DateTime.Now Is there any way to get the current local time for a sp...
Carniola asked 10/1, 2013 at 5:45

2

I am working in Namibia. Namibia is not an option on the Windows Region and Language settings, but share most cultural specifics with South Africa, so we select English South Africa and then custom...
Nunley asked 8/9, 2011 at 7:56

2

Is there a centralized way to have the WPF UI to respect the customized decimal separator set in Control Panel -> Regional Settings? When I bind a double valued data to a text box, I want to ente...

1

Solved

If I have the culture code for a country/language combination, is it possible to from this, find the text direction. For example for en-US how can I get from this that the text direction is left ...
Forbidding asked 2/11, 2012 at 16:15

3

Solved

Can CultureInfo.CurrentCulture ever be null? A null value would crash my program, which I don't want. So I'm asking, to be safe, do I need to do? var culture = CultureInfo.CurrentCulture ?? Cultu...
Giveaway asked 13/11, 2012 at 10:32

8

Solved

We have an application parsing date/time values in the following format: 2009-10-10 09:19:12.124 2009-10-10 12:13:14.852 2009-10-10 13:00:00 2009-10-10 15:23:32.022 One particular server all of ...
Gavel asked 16/10, 2009 at 19:2

3

I am working on a .net 4.5 application that needs to be mult lingual supporting multi cultures etc. The following is sample list of Countries/Languages Russia / Russian Belgium / French Belgium ...
Wendiwendie asked 16/10, 2012 at 14:26

2

In a VSTO project for Excel written in C#, I need to get the Range object from a string list of cells. Here is a simplified version of the problem: string strRange = "A1:A2,A5"; Excel.Range r = s...
Tinderbox asked 24/9, 2012 at 8:33

4

Solved

I try to convert string to datetime but each time I get : String was not recognized as a valid DateTime. Code is: string format = "dd/MM/yyyy"; obj.TransDate = DateTime.ParseExact(lbl_TransD...
Valerio asked 12/4, 2012 at 12:0

3

Solved

I just ran into something very strange, and was just wondering if I was missing something. I was trying to parse a string (with thousand separators) into a double, and found the below issue. Cult...
Vitriolic asked 6/9, 2012 at 12:31

2

Solved

How do I pass an IFormatProvider to a StreamWriter? Specifically I want to create a new StreamWriter("myfile.txt", CultureInfo.InvariantCulture); TextWriter and StringWriter have a parameter for ...
Stilly asked 17/8, 2012 at 19:9

© 2022 - 2024 — McMap. All rights reserved.