Umbraco/Reference/umbraco.library/GetMedia

Umbraco.library.GetMedia
The method is used to get information of files in the media library - such as filename, size, height, width.

Parameters

GetMedia(int MediaId, bool Deep);

Integer  MediaId Boolean  Deep

Return value

The method returns a XPathNodeIterator with the information of selected file.

Usage 

Getting the url of a media file 

Getting the url of a media file with the new xml structure 