Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have a sheet, let's say its ID is 'hseUuw'.
I have a table on that sheet. let's say its ID is 'zBxhpPX'.
var existingTable = app.GetSheet("hseUuw").GetTable("zBxhpPX");
existingTable is not null. But when I look at its properties in the Visual Studio debugger, they are all throwing an exception of type 'System.NullReferenceException'.
I wanted to look at its properties... but that is null.
Does anybody know why?
Thanks,
Shane.
Hi,
It looks like you are using version 1.0.0 of the .Net SDK? In the .Net SDK 1.0.0 there is an error when deserializing tables. I recomend that you uppgrade to version 1.0.1 or 1.0.2 of the .Net SDK.
// Lars-Göran Book
hi,
try to read its property by creating one more variable instead of reading it while debugging.
var property = existingtable.properties;
regards,
Prabhu appu
Hi,
thanks for your reply. Are you saying that the Visual Studio Debugger isn't working correctly?
As expected, doing this:
var existingTableProperties = existingTable.Properties;
results in a null value for 'existingTableProperties'.
Regards,
Shane.
Hi,
the .Net SDK is "lazy" which means that the data will be fetched when you access it thats why youexperience your problems when debugging.
If you want to look at the properties you must access the properties.
var title = existingtable.Properties.Title
You can also force the SDK to retrieve these by calling GetProperties() and GetLayout().
// Lars-Göran Book
Hi,
thanks for your reply.
var existingTable = app.GetSheet("hseUuw").GetTable("zBxhpPX");
var existingTableProperties = existingTable.GetProperties();
var test = existingTable.Properties.Title;
In the code sample above:
existingTable is not null,
existingTableProperties is null
reading property 'Title' throws an exception (because Properties is null)
Regards,
Shane.
Hi,
It looks like you are using version 1.0.0 of the .Net SDK? In the .Net SDK 1.0.0 there is an error when deserializing tables. I recomend that you uppgrade to version 1.0.1 or 1.0.2 of the .Net SDK.
// Lars-Göran Book
Yeah - that's made a difference!
Thanks.
this works!!!!!
var test = (String) existingTable.Properties.Title;
corchi
Yes, it does with 1.0.2.
It certainly doesn't with 1.0.0 of the SDK.