Information générale
Catégorie:
The Mere Mortals .NET Framework
///
/// InventoryPK
///
public Guid InventoryPK
{
get
{
if (this.Row != null)
return (Guid)mmType.GetNonNullableDbValue(this.Row["InventoryPK"], "System.Guid");
else
return this._inventoryPK;
}
set
{
if (this.Row != null)
this.Row["InventoryPK"] = value;
this._inventoryPK = value;
}
}
private Guid _inventoryPK;
The problem comes in if I check to see if a value has been assigned. If the row has been created and nothing has been assigned, I get an error that it can't cast null to the Guid. In this instance, I can set the default when the row is created. In other circumstances, there really isn't a default.
Jeff
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement