I have the following RadClientDataSource:
<telerik:RadClientDataSource runat="server" ID="rdsCounty">
<DataSource>
<WebServiceDataSourceSettings ServiceType="GeoJSON">
<Select Url="Arizona.json" DataType="JSON" ContentType="application/json" />
</WebServiceDataSourceSettings>
</DataSource>
</telerik:RadClientDataSource>
...which is being consumed by a RadMap (along with other RadClientDataSource controls) like so:
<telerik:RadMap runat="server" ID="rdmTest" Width="800" Height="600">
<ClientEvents OnShapeCreated="configureShape" OnShapeClick="clickShape" OnLoad="zoomToContiguousUSA" />
<LayersCollection>
<telerik:MapLayer Type="Bing" Key="my key here" />
<telerik:MapLayer Type="Shape" ClientDataSourceID="rdsState" />
<telerik:MapLayer Type="Shape" ClientDataSourceID="rdsCounty" />
</LayersCollection>
</telerik:RadMap>
Is it possible to change the URL from "Arizona.json" to "Illinois.json"? I want to do this on the client, using javascript, in response to user action. I've looked at the client side API for the RadClientDataSource and I don't see how this could be done. I could also load Illinois.json manually, but I've tried something like this:
map.layers[2].setDataSource(JSON.parse(IllinoisFileContents));
...but that doesn't seem to work.
Is there a proper technique for this?