Closed sharaditmca closed 11 years ago
There's no library for OpenLayers. You might want to check tutorials on their site. What kind of tutorials are you looking for? There are mostly example projects available if you look at the code.
Firstly thanks for your response . As u know all features of openlayers are in javascript . but i want less javascript and more c# code. I don't think it is worthwhile to totally eradicate javascript. so i want tutorials in script# which contain openlayers features.
What you're looking to do is write a stub out a S# interface to OpenLayers. I've been meaning to do that for OL3, but don't have time at the moment.
Thanks for chiming in @theoutlander
@sharaditmca I'd recommend looking through the sources for how the import libraries for html, jquery, node etc. were created and use them to try to create something similar for openlayers.
thanks @nikhilk .Can u give some suggestions about how to import libraries for html , jquery,etc.
Look in the in the repository for source code constituting those out-of-box import libraries - that is what I meant.
I download "Openlayers api " from NuGet in script# project ,but it could not work ,finally can't find any solution of question "How to use Openlayers in script#?"
For Script# to interoperate with existing javascript libraries, you need an "import library". There are existing libraries for html, jquery, knockout etc but there currently isn't one for OpenLayers. If you want to create an import library for Open Layers they're not very complicated. you can see what the code is like by looking at the Knockout library or one of the other out-of-the-box import libraries.
@sharaditmca - You can look at the code under https://github.com/nikhilk/scriptsharp/tree/cc/src/Libraries for examples of how import libraries are created.
Start out small by trying to expose one javascript method in a S# class. Once you've tried that, ask more specific questions if you run into issues. I can try to write a wiki article on stubbing if when get a chance.
Also, I plan on stubbing the OpenLayers 3 API in S# at some point, but I just haven't had a chance to do that yet. Maybe sometime early next year.
I'm new to using Script#. Can you provide a any tutorials related to script# , sharepoint and openlayers.
Thanks Sharad