private void Daf() { string value; HebrewDateFormatter hdf = new HebrewDateFormatter(); JewishCalendar jc = new JewishCalendar(); jc.InIsrael = true; hdf.HebrewFormat = true; value = hdf.formatDafYomiBavli(jc.DafYomiBavli); lblDaf.Text = value; }
private void Hagim() { string value; HebrewDateFormatter hdf = new HebrewDateFormatter(); JewishDate jd = new JewishDate(); JewishCalendar jc = new JewishCalendar(); jd.resetDate(); hdf.HebrewFormat = true; jc.InIsrael = false; value = hdf.formatYomTov(jc); lblHolides.Text = value; }
/// <summary> /// show full date and year in the application /// </summary> public void showDate() { string value; HebrewDateFormatter hdf = new HebrewDateFormatter(); JewishDate jd = new JewishDate(); JewishCalendar jc = new JewishCalendar(); jd.resetDate(); hdf.HebrewFormat = true; jc.InIsrael = true; value = jc.GregorianDayOfMonth.ToString() + "/" + jc.GregorianMonth.ToString() + "/" + jc.GregorianYear.ToString(); ILDate.Text = value; }
public void Pharsha() { string value, value2; HebrewDateFormatter hdf = new HebrewDateFormatter(); JewishCalendar jc = new JewishCalendar(); JewishDate jd = new JewishDate(); jc.InIsrael = false; hdf.HebrewFormat = false; value = hdf.formatParsha(jc); lblPharsha.Text = value; value2 = jc.ParshaIndex.ToString(); lblIsHead.Text = value2; }
/// <summary> /// show to current day /// </summary> private void ShowDay() { //Thread.CurrentThread.CurrentCulture = new CultureInfo("he-IL"); //string day = "dddd"; //lblShowDay.Text = DateTime.Now.ToString(day); /*******************************************************************/ string value1, value2; HebrewDateFormatter hdf = new HebrewDateFormatter(); JewishDate jd = new JewishDate(); JewishCalendar jc = new JewishCalendar(); hdf.HebrewFormat = false; jc.InIsrael = true; //hdf.LongWeekFormat = true; value1 = hdf.formatDayOfWeek(jd); //value2 = jd.DayOfWeek.ToString(); if (value1 == "Sunday") { value1 = "ראשון"; } if (value1 == "Monday") { value1 = "שני"; } if (value1 == "Tuesday") { value1 = "שלישי"; } if (value1 == "Wednesday") { value1 = "רביעי"; } if (value1 == "Thursday") { value1 = "חמישי"; } if (value1 == "Friday") { value1 = "שישי"; } if (value1 == "Saturday") { value1 = "שבת"; } lblShowDay.Text = value1; /*******************************************************************/ }
/// <summary> /// show hebrew date and convert it to leetres /// </summary> /// private void ShowHebDate() { //CultureInfo ci = CultureInfo.CreateSpecificCulture("he-IL"); //ci.DateTimeFormat.Calendar = new System.Globalization.HebrewCalendar(); //lblHolides.Text = (DateTime.Today.ToString("d MMM yyyy", ci)); /****************************************************************************/ string value; HebrewDateFormatter hdf = new HebrewDateFormatter(); JewishDate jd = new JewishDate(); JewishCalendar jc = new JewishCalendar(); // jd.resetDate(); jc.InIsrael = false; hdf.HebrewFormat = true; value = hdf.format(jd); lblHebDate.Text = value; }