My favorites | Sign in
Project Home Wiki Issues Source
READ-ONLY: This project has been archived. For more information see this post.
Search
for
HDateEditor  
HDateEditor - gtk sharp date time widget
Updated Feb 4, 2010 by fr.dan...@gmail.com

Introduction

This widget is a date time picker, supporting custom formatting options.

Details


Methods:

bool IsDateValid() - returns true if the date-time string is valid

Properties:

DateTime CurrentDate gets/sets the current date-time
DateTimeFormatTypeEnum DateTimeFormatType gets/sets the current date-time format type
Gdk.Color ErrorColor gets/sets the text color when format is invalid

Events:

EventHandler DateChanged - raised when date-time value is changed


  • Formatting types:
  1. Custom
  2. FullDateTime
  3. ShortTime
  4. ShortDate
  5. LongDate
  6. LongTime
  • Custom format example:
  • this.dateEditWidget.DateTimeFormatType = HollyLibrary.DateTimeFormatTypeEnum.Custom;
    this.dateEditWidget.CustomFormat       = "dd/MM/yyyy 'and time is:' HH:mm:ss";
    this.dateEditWidget.CurrentDate        = DateTime.Now;
  • Simple short date-only format example:
  • this.dateEditWidget.DateTimeFormatType = HollyLibrary.DateTimeFormatTypeEnum.ShortDate;
    this.dateEditWidget.CurrentDate        = DateTime.Now;

Comment by davidca...@gmail.com, Oct 7, 2008

Good stuff!! is there a way to show only the calendar and not the clock? All I need is a Date picker. Thanks!!

Comment by adamtaun...@gmail.com, Dec 7, 2008

Ditto davidcanar, my apps need just a date picker in some cases.

Powered by Google Project Hosting