Welcome Guest Search | Active Topics | Sign In | Register

Gridcell is replaced with '_DateFor0at', when onloss of focus from 'DateTimeColumn'. Options
bskumar
Posted: Friday, October 30, 2009 10:49:38 AM
Rank: Member
Groups: Member

Joined: 9/22/2009
Posts: 24
Hi,
I am using EOGrid first time in my application. I had replaced asp:datagrid with "EO:Grid" control.
Gridcell is replaced with '_DateFor0at', when onloss of focus from 'DateTimeColumn'. Following is the code snippet of creating columns dynamically.


Code: C#
string _DateFormat = GetDateFormat();
		TimeSpan subDate = new TimeSpan(1, 0, 0, 0);

		DatePicker dtPicker = new DatePicker();
		dtPicker.PickerFormat = _DateFormat;
		dtPicker.PickerHint = _DateFormat;
		dtPicker.PopupExpandDirection = ExpandDirection.BottomRight;
		dtPicker.Width = 100;

               .............
               .............

			DateTimeColumn calPatentGrantedOn = new DateTimeColumn();
			//calPatentGrantedOn.AllowEdit = true;
			calPatentGrantedOn.DataFormat = "{0:_DateFormat}";
			calPatentGrantedOn.DataField = "GrantedOn";
			calPatentGrantedOn.HeaderText = "Granted On";
			calPatentGrantedOn.DatePicker = dtPicker;
			calPatentGrantedOn.DataType = GridColumnDataType.DateTime;

			//calPatentGrantedOn.DatePicker = new DatePicker();
			//calPatentGrantedOn.DatePicker.PickerFormat = _DateFormat;
			//calPatentGrantedOn.DatePicker.PickerHint = _DateFormat;
			//calPatentGrantedOn.DatePicker.Parent.ID = cctlPatentInfoDataGrid;
			//calPatentGrantedOn.DatePicker.PopupExpandDirection = ExpandDirection.BottomRight;
			calPatentGrantedOn.DatePicker.MaxValidDate = DateTime.Today.Subtract(subDate);
			//calPatentGrantedOn.DatePicker.Width = 100;

			cctlPatentInfoDataGrid.ColumnTemplates.Add(calPatentGrantedOn);
			cctlPatentInfoDataGrid.Columns.Add(calPatentGrantedOn);
			cctlPatentInfoDataGrid.Columns[2].Width = 130;
			cctlPatentInfoDataGrid.ColumnTemplates[2].Width = 130;
                       ...................
                       ...................
		DateTimeColumn patentValidTill = new DateTimeColumn();
		//patentValidTill.AllowEdit = true;
		patentValidTill.DataFormat = "{0:_DateFormat}"; 
		patentValidTill.DataField = "ValidTill";
		patentValidTill.HeaderText = "Valid Till";
		patentValidTill.DataType = GridColumnDataType.DateTime;
		//patentValidTill.DatePicker = new DatePicker();
		patentValidTill.DatePicker = dtPicker;		
		//patentValidTill.DatePicker.PickerHint = _DateFormat;
		//patentValidTill.DatePicker.PopupExpandDirection = ExpandDirection.BottomRight;
		//patentValidTill.DatePicker.Width = 100;
		cctlPatentInfoDataGrid.ColumnTemplates.Add(patentValidTill);
		cctlPatentInfoDataGrid.Columns.Add(patentValidTill);
		cctlPatentInfoDataGrid.Columns[4].Width = 130;
		cctlPatentInfoDataGrid.ColumnTemplates[4].Width = 130;




I am referring 'Edit Grid Data - Excel Style' example.

Thanks,
Kumar.
eo_support
Posted: Saturday, October 31, 2009 11:00:08 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
I am sorry but what is your question?
bskumar
Posted: Sunday, November 1, 2009 4:11:19 AM
Rank: Member
Groups: Member

Joined: 9/22/2009
Posts: 24
Hi,

First sorry for typo error. I added 'DateTimeColumn' to a EOGrid. Following are the issues i am facing with EOGrid.

1. Picker hint is not showing by default.
2. 'DateTimeColumn' ignoring Max and Min valid date proporties .
3. After selecting the date from the date picker.Selected date si showing properly in the 'DateTimeColumn' cell. But selected date is retaining with '_DateFor0at' on loss of focus from 'DateTimeColumn' cell.

Thanks in Advance,
Kumar
eo_support
Posted: Monday, November 2, 2009 7:10:28 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
Hi,

#1 and #2 appears to be a bug. We will look into it and see what we can do. #3 is your code error. "{0:_DateFormat}" literally format to "_DateFormat". The string literal has nothing to do with your variable _DateFormat.

Thanks
eo_support
Posted: Sunday, November 8, 2009 11:03:48 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
Hi,

We have fixed #1 and #2. Please let us know if you want to try the new build with the fix.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.