Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Love the Grid Data type - does exactly what I need :) I'm trying to import content into Umbraco using the Web API and I'm struggling to set the Grid Data Type properly. I've tried an object but its failed. Code below is what I'm using. Any advice??
venue = contentService.GetById(venueId);
var special = new Special();
special.featureBeer = beer;
special.isMonday = monday;
special.summary = summary;
Microsoft.CSharp.RuntimeBinder.RuntimeBinderException: The best overloaded method match for 'Umbraco.Core.Models.ContentBase.SetPropertyValue(string, string)' has some invalid arguments at CallSite.Target(Closure , CallSite , Object , String , Object ) at Umbraco.Core.Models.ContentBase.SetValue(String propertyTypeAlias, Object value)
Any advice/help would be greatly appreciated :)
haveyou tried serializing to JSON before inserting? also I think it will have to be a List<Special> as this datatype allows a list of values to be used.
Thanks Stephen - I ended up attaching a debugger and seeing the JSON, so manage to use that and it worked a treat :)
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted