We are going to get the ScreenPoint of a MapPoint. When we are using the map-point as center of the map and then using the toScreen() method then we are getting the ScreenPoint with the value of x & y as NaN. We are using the API version 3.x
Please help why the x and y property value is NaN
Without seeing your code, it's impossible to tell what's causing the problem. However, to accomplish what you're trying to do, I would recommend something like the following:
var mapCenter = map.extent.getCenter();
var screenCenter = map.toScreen(mapCenter);
console.info(screenCenter.x.toString() + ", " + screenCenter.y.toString());