Based on the data, I need to dynamically generate a graphic in my ASP开发者_StackOverflow.NET page. What is the best way to do this. Is this easier to implement in Silverlight.
You can use any graphics library, including the classes in the System.Drawing
namespace.
no, SL in not absolutely needed, you can draw it line by line using GDI+ (Managed GDI APIs) on the server side from C#.
SL could help a bit but it really depends if you want then to bind your application to a plugin. I would not, just to be cross platform (including mobile devices)...
- You can create the image on the server side and returns via httpHandler
- TO draw on the client side using javascript you can find a special librarise like this
- You can use Silverlight or Flash
- I'm not sure but probably it can be done via CSS3
I would seriously recommend using http://raphaeljs.com/
You could create server side code to do it using system.drawing, but Raphael can do it all in the browser, saving you a round trip.
精彩评论