The reason that every property in your stored table is empty is because WriteEntity and ReadEntity use an empty object to store and write data.
You delegate the serialization of your object to 'tableEntity', but none of your properties exist.
Suggestion: you will need to implement all your SerializableTableEntity properties inside a class that comes from TableEntity, contain a variable of this type inside the SerializableTableEntity object and delegate each get / set member property from SerializableTableEntity to this new object.
It makes sense?
EDIT: sample code as requested (you wont get it though)
[DataContract] public class SerializableTableEntity : ITableEntity { private CustomEntity tableEntity; public string ETag { { get { return tableEntity.ETag; } set { tableEntity.Etag = value; } } public string PartitionKey { get { return tableEntity.PartitionKey; } set { tableEntity.PartitionKey = value; } } public string RowKey { get { return tableEntity.RowKey; } set { tableEntity.RowKey = value; } } public DateTimeOffset Timestamp { get { return tableEntity.Timestamp; } set { tableEntity.Timestamp = value; } } public string PropertyOne { get { return tableEntity.PropertyOne; } set { tableEntity.PropertyOne = value; } } public SerializableTableEntity() { tableEntity = new CustomEntity(); } public void ReadEntity(IDictionary<string, EntityProperty> properties, Microsoft.WindowsAzure.Storage.OperationContext operationContext) { tableEntity.ReadEntity(properties, operationContext); } public IDictionary<string, EntityProperty> WriteEntity(Microsoft.WindowsAzure.Storage.OperationContext operationContext) { return tableEntity.WriteEntity(operationContext); } } public class CustomEntity : TableEntity { public string PropertyOne { get; set; } }
source share