I am relatively new to Silverlight development and I am trying to figure out how to get data out of a silverlight control that I have made.
I have a Silverlight control that gathers a bunch of graphical data points. The Silverlight control is embedding in a asp.net webforms application. The page that is displaying the control also does other data specific functions and when the user clicks a button I need to perform some manipulation of the data (both webform data and the data contained in the Silverlight control) and then save the data with 1 call to the DB.
My question is how do I get the data out of the Silverlight control from my webform to be able to put the data together for the save?
My initial thought was to make the data in the Silverlight control accessible via Javascript and then on the button click, save the Silverlight control's data to some html control and then allow the regular webform post to occur and read the data server side. Is there a better way to do this as it feels a little messy.
Note: I am using .NET 3.5 and Silverlight 3.0.