Thank you for your reply! To be clear, though, I am not wanting to load a kml from a local machine/client to the silverlight app/host/server. Rather, I would like the host map data to come from a kml file on the server (with no user interaction). This can be done with Javascript, I believe. Am I still barking up the wrong tree?
Another way to clarify is that I do not have the capability to serve out my own data as a service. Therefore I must find a way to host my data in another form (perhaps similar to a Graphics Layer stored with the Silverlight Assets?). If this is not viable, maybe Silverlight is not the way to go for me. I do see that others on this list have asked about ways to host kmls and shapefiles directly in their maps.
Did you look at the SDK sample? http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#KmlLayerSimple
It pulls KML data straight from a website:
<esri:KmlLayer ID="KmlLayer" Url="http://kml-samples.googlecode.com/svn/trunk/KML_Samples.kml" />
You cannot read files directly from a local folder on disk if you are using Silverlight (that would be a HUGE security risk). You can use the OpenFileDialog class to let the user browse to a kml file. This will give you a stream to the kml file. Next use the SetSource method and use the stream as the parameter. Last add KML layer that to your map.
Something along the lines of this (untested):OpenFileDialog openFileDialog1 = new OpenFileDialog(); openFileDialog1.Filter = "KML files (.kml)|*.kml|Compressed KML files (.kmz)|*.kmz|All Files (*.*)|*.*"; openFileDialog1.FilterIndex = 1; bool? userClickedOK = openFileDialog1.ShowDialog(); if (userClickedOK == true) { System.IO.Stream fileStream = openFileDialog1.File.OpenRead(); var layer = new KmlLayer(); layer.SetSource(myFiledDialog.File); myMap.Layers.Add(layer); }