This project is read-only.

Cool Menu - How to load images from database?

Dec 15, 2008 at 5:39 AM
How can we load images from a database dynamically instead of a fixed folder.
Dec 15, 2008 at 1:20 PM
Since there is no direct way to pull data from a database in Silverlight.  You would first have to build a web-service, HttpHandler, or ASPX page to serve up the image.  Once you have done this, you can specify an Image with the appropriate path.  For example:
            <sc:CoolMenu Height="130" MaxItemHeight="100" MaxItemWidth="100">
                        <sc:CoolMenuItem Text="Box">
                                <Image Source="" Stretch="UniformToFill" Margin="5"  />
Below are a few resources that might help you:

I hope this helps!

Jan 22, 2009 at 9:31 AM
I see a Observable Collection and Binding properties on the CoolMenu object.
I guess you should be able databind the Source of the Image to a Uri.
There are enough examples on that on the web.

Does this work in CoolMenu?

Jan 22, 2009 at 1:06 PM
I am currently working on a major refactoring for this control which should allow for databinding.  I will post an example of this as soon as the refactoring is completed.