Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What is wrong with a line like this? DateTime.Parse(myString)

Answer Posted / soner gönül

- Different cultures uses different standard date and time formats. This overload can create ambiguous values for the same string in different cultures. Eg: What should "01/02/2016" parsed as? 1 February? 2 January? It depends.

- The Calendar used by CurrentCulture might not have this date and time because of it's boundries.

If anyone interested, I wrote an article in Turkish about that subject.

http://sonergonul.net/datetime-parse-string-kullanmayi-birakamaz-miyiz/

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How information about the user's locale can be accessed?

1109


What is a response cookie?

1170


How ASP and ASP.NET page works? Explain about asp.net page life cycle?

1076


What type of code, client-side or server-side, is found in a code-behind file of a Web page?

1005


What is masterpage?

1001


How may clustered index we can create in table?

1054


in which protocol ASP.NET WEB API Work?

1156


How would you turn off cookies on a page of a website?

987


How to retrieve user name in case of Window Authentication?

817


What is authorization in asp.net?

1130


What is syntax code to send email from an asp.net application?

1066


What is the difference between asp.net and mvc?

1172


What is break mode?

996


Can we have multiple worker process in an ASP.NET application? If so then how it has been handled by application? And who handles it?

1054


What do you mean by View State and what is its role?

1162