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
I have downloaded Merchello from github and start Merchello.FastTrack.Ui. But when the website is loading it generated an error:
var images = Model.GetPropertyValue<List<IPublishedContent>>("image");
Because the product's cannot beloaded, then the home page cannot show the products.
Note: When I view the products from admin side, the product's images are available.
Here is my solution with a custom function:
/// Get product image from IProductContent Model
/// <param name="iProductContent">This model is provided by view file when it call to view product image</param>
public static System.Collections.Generic.List<string> GetProductImageFromModel(Merchello.Web.Models.VirtualContent.IProductContent iProductContent)
System.Collections.Generic.List<string> images = new System.Collections.Generic.List<string>();
var properties = iProductContent.Properties;
foreach (var pro in properties)
if (pro.PropertyTypeAlias == "image")
var id = pro.DataValue;
var umbHelper = new Umbraco.Web.UmbracoHelper(Umbraco.Web.UmbracoContext.Current);
var content = umbHelper.Media(id);
Somehow Model.GetPropertyValue<List<IPublishedContent>> doesn't work. So I have to look into its property value and try to take image Id to find image url.
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted