I am trying to change the CSS of the feature from feature layer through the javascript API 3.2.1 .
Please check the attached file of pin image.
Thanks
Kamal,
You do not work with the CSS for symbols in the JS API as they are mainly SVG graphics. You need to change the Symbol class for that graphic.
Robert
I have updated the image of a pin . please check it again then you might be clear what i am asking for
So are you setting the point symbol using a picturemarkersymbol?
Robert,
No , it is the image coming from the feature layer. we are not setting anything in the javascript.
OK now I understand. So one way to handle this is to get the pins geometry through a query and set the symbol you want to the graphic.
I have already added the symbol for a graph and that is for filling color of the polygon. but now i want to change the CSS of pins which are under the polygon.
Here is the code
var symbol = new SimpleFillSymbol( SimpleFillSymbol.STYLE_SOLID, new SimpleLineSymbol( SimpleLineSymbol.STYLE_SOLID, new Color([r,g,b,0.9]), 4 ),new Color([r,g,b,0.5]));
var graphic = new Graphic(query, symbol); map.graphics.add(graphic);
Aangemelde leden kunnen berichten plaatsen, updates volgen en meer. Nieuw hier? Registreer een gratis account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.