Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at

  • Owen Hope 119 posts 140 karma points
    May 07, 2011 @ 01:41
    Owen Hope

    Get Media URL -- problem .NET (not XSLT)


    Currently using Umbraco

    I am trying to get the Image URL of a Media node, but all I can ever return is the Media Node ID.

    I pass in the Media Node ID but I can never get the URL of that Node.

    I am using .NET for this user control so please help me with .NET solutions rather than XSLT.





  • Owen Hope 119 posts 140 karma points
    May 07, 2011 @ 01:55
    Owen Hope

    Currently I am using this method:

    string videoThumbnailID = galleryVideo.GetProperty("videoMediumThumbnail").Value;
    int thumbID = int.Parse(videoThumbnailID);
    Media m = new Media(thumbID);
    string imageUrl = m.getProperty("umbracoFile").Value.ToString();

    But imageUrl is returning the ID of the Media Node, not the URL.




  • Jan Skovgaard 11264 posts 23594 karma points MVP 9x admin c-trib
    May 07, 2011 @ 11:56
    Jan Skovgaard

    Hi Owen

    Try having a look at this post:

    Does that do the trick fr you?


Please Sign in or register to post replies

Write your reply to: