Is it possible to create a Custom Geocoder and provide a custom 'complete' function?

based on the example in Sandcastle. for example, i want to show a point entity after geocoder and flyto? Thanks.

Whether you are using a custom geocoder or not, there is a complete event you can subscribe to. Here’s a simple example that does exactly what you want:

var viewer = new Cesium.Viewer(‘cesiumContainer’);

var lastGeocode = viewer.entities.add({

point: {

pixelSize: 20,

heightReference : Cesium.HeightReference.CLAMP_TO_GROUND



var removeListener = viewer.geocoder.viewModel.complete.addEventListener(function(){

lastGeocode.position =;