I'm using printtask to make a print of the map. I add some graphics to map.graphics layer. In case of point or polygon the print task will actually print the result but if its a polyline the result will be only seen on map itself (as per result of map.graphics.add) but not on the printed image/pdf. I dont think the symbol is wrong since i use same marker for line and polygon...
pointStyle : new esri.symbol.SimpleMarkerSymbol(esri.symbol.SimpleMarkerSymbol.STYLE_SQUARE, 20, null, new dojo.Color([255,255,0,0.5])); linepolyStyle : new esri.symbol.SimpleFillSymbol(esri.symbol.SimpleFillSymbol.STYLE_SOLID, new esri.symbol.SimpleLineSymbol("dashdot", new dojo.Color([255,0,0]), 5), new dojo.Color([255,255,0,0.25]));
pseudo code if point{ add graphic to map.graphics } else //so if polyline or polygon { add graphic to map.graphics }
Hopefully someone already met and solved this issue:)
The reason you need to do this is that you have to use different symbol types for different geometry types. Points require a marker symbol, lines require a line symbol and polygons require a fill symbol.