With this package it's easier to use DAMP in Razor. It can work with the xml or id's that DAMP saves. If you do Model.propertyName it will return a list you can loop through. It also has the following properties:
IsXml - Returns a boolean if the data is stored as xml.
PropertyData - Returns a string with the raw data.
First - Returns the first item from the list.
Count - Returns how many media items are selected.
Any - Returns a boolean to see if any items are selected.
Xml - Returns all media items as DynamicXml.
Skip(int) - Used for paging.
Take(int) - Used for paging.
Each object in the list has the following properties:
Id - Returns the id of the media item.
Name - Returns the name of the media item.
Type - Returns the Media Type of the media item.
File - Returns the url of the media item if it exists.
Url - Also returns the url of the media item if it exists.
Alt - Returns the alt property. If it doesn't exist it will return the name.
Resized - Returns the resized property if it exists.
Xml - Returns the current media item as DynamicXml.
Children - Returns the children of this media item as a list.
Crops - Returns a DynamicDictionary with all the crops.
TypedCrops - Returns the crops as a Dictionary<string, string>.
There are 2 versions of this package. The first version is called the DAMP Razor Model and works on Umbraco 184.108.40.206 and higher with the old Razor: http://bit.ly/SV0jc6
The second version is called the DAMP Property Editor Value Converter and works on Umbraco 4.10 and higher with the new Razor: http://bit.ly/VTMAFC
You already need DAMP installed: http://bit.ly/ijPtF9
The example packages will probably only work on Umbraco 4 and not 6. They're still a nice demonstration so you can try them on v4.
If you want some old Razor (4.7) examples you can install the DAMP Razor Model Samples package: http://bit.ly/RWsdBr
If you want some new Razor (4.10) examples you can insall the DAMP Property Editor Value Converter Samples package: http://bit.ly/VTMpKh
Here is a quick video on how to use the DAMP Razor Model: http://www.screenr.com/qvj8
Here is a quick video on how to use the DAMP Property Editor Value Converter: http://www.screenr.com/g2H7
If you have any questions about this package you can ask them here: http://bit.ly/RWdVBh