Welcome Guest Search | Active Topics | Sign In | Register

Possible Grid Bug with nullable long type? Options
Andre
Posted: Thursday, September 25, 2008 6:16:08 AM
Rank: Member
Groups: Member

Joined: 8/19/2008
Posts: 14
Hi

I am using a grid with 2 columns:

<eo:TextBoxColumn Name="ID" HeaderText="ID" DataField="IDString" />

<eo:TextBoxColumn Name="AnotherID" HeaderText="AnotherID" DataField="vwMasterPolicyCostScheduleID" />


I use subsonic by the way...

anyway

the item I am binding to has a property:

=====================================================
My wrapped subsonic property
=====================================================
public string IDString
{
get
{

if (this.VwMasterPolicyCostScheduleID != null)
return this.VwMasterPolicyCostScheduleID.ToString();
else
return string.Empty;
}
}
=====================================================
AND subsonic's property
=====================================================
[XmlAttribute("VwMasterPolicyCostScheduleID")]
public long? VwMasterPolicyCostScheduleID
{
get
{
return GetColumnValue<long?>("vwMasterPolicyCostScheduleID");
}

set
{
SetColumnValue("vwMasterPolicyCostScheduleID", value);
}

}
=====================================================


IDString shows on the grid and VwMasterPolicyCostScheduleID doesn't. When I place a watch on the property, all the items in the collection have valid values.

A possible bug?


Will the grid in future have events exposed for RowCreated or RowDataBound?
eo_support
Posted: Thursday, September 25, 2008 7:13:24 AM
Rank: Administration
Groups: Administration

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

I do not believe the Grid supports Nullable types. To get the similar result, you can replace the int value with a string value, that way you would be able to explicitly control how the result is formatted. Sorry about that!

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.