473,569 Members | 2,768 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

System::DateTim e::Parse

I would like to parse a hebrew date into a System::DateTim e variable:

System::Globali zation::Culture Info ^CulInfo =
gcnew System::Globali zation::Culture Info("he-IL");
CulInfo->DateTimeForm at->Calendar =
gcnew System::Globali zation::HebrewC alendar;
CulInfo->DateTimeForm at->DateSeparato r = " ";

System::DateTim e dt;

dt.Parse(L"×›×´ ×’ ×*יסן תשס״ח", CulInfo);

Unfortunately an exception is fired:

The string was not recognized as a valid DateTime. There is a unknown
word starting at index 0.

Any ideas what could be wrong here?

J.M.
Jun 27 '08 #1
0 1129

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
12510
by: Tobias Olbort | last post by:
Hello, why does this not work (the OS runs with german settings): DateTimeFormatInfo dtFI = new DateTimeFormatInfo(); dtFI.FullDateTimePattern = "ddd MMM dd HH:mm:ss yyyy"; dtFI.AbbreviatedDayNames = new string {"Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"}; dtFI.AbbreviatedMonthNames = new string {"Jan", "Feb", "Mar",
0
1438
by: Paul Bowman | last post by:
HI All I have a date 20020101T000000, 00+00 which is, apparently in the ISO8601 format. I need to get this date into a DateTime instance. This format is different to the style given in the MS literature. So it is not recoqnised by the Parse method. So I guess I need to use a custom formatter to convert it to what I
3
2781
by: andrewcw | last post by:
I save date time into my XML files like this: MesObj.theTime=System.DateTime.Now; "5/4/2004 8:50:30 AM" BUT that string is NOT recognizable as a valid dateTime when the data is read back from file ( i.e. schema strong data type dateTime It seems to follow this test protocal : DateTime transactDate = XmlConvert.ToDateTime(timeTest); I...
1
13292
by: vooose | last post by:
Consider an application which has *many* references to DateTime.Parse(string); Is there a way, say when the application first starts up to force this method to use a specific IFormatProvider, so every DateTime.Parse(string) is really DateTime.Parse(string, format);
4
4479
by: DWW | last post by:
System.DateTime returns a string with the date and time. I want to convert the time to an integer, for example, convert 10:24:45 to 102445. Much research has turned up a myriad of variations on formatting using Parse and DateTimeFormatInfo, but nothing that returns the time as an integer. Any ideas? Thanks. DW
3
6801
by: Kevin Kenny | last post by:
Dear All, I have a date time validation method thus: public static bool IsDate(string date, System.IFormatProvider provider) { try { DateTime.Parse(date, provider) return true; } catch (System.FormatException) return false;
4
35872
by: tshad | last post by:
Is there any difference between convert.ToDateTime and System.DateTime.Parse? I am using them both and they seem the same. Is one better to use than another? Thanks, Tom
8
6134
by: Rico | last post by:
Hello Everyone, I observed something strange in some quick testing code: void Button1Click(object sender, System.EventArgs e) { CultureInfo culture = new CultureInfo("th-TH", false); tbxDisplayResult.Text = DateTime.Parse(tbxInputArea.Text, culture).ToString("yyyy MMMMMMMMMM dd");
5
5130
by: js | last post by:
I have a textbox contains text in the format of "yyyy/MM/dd hh:mm:ss". I need to parse the text using System.DateTime.Parse() function with custom format. I got an error using the following code. Could someone help me with the customization? Thanks. String was not recognized as a valid DateTime. at System.DateTimeParse.Parse(String s,...
0
7695
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7612
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7922
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
8119
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
0
7964
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
6281
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
5218
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
1
2111
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1209
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.