我试图让鼠标的坐标点击amcharts饼图的切片。除切片外,它适用于整个页面。 event.pageX和event.clientX不起作用,返回undefined。我想要关于页面的坐标。
{
"event": "pullOutSlice",
"method": function (event) {
var relX = event.pageX;
var relY = event.pageY;
}
}
答案 0 :(得分:3)
这是你在找什么? https://jsfiddle.net/6w78zmo9/1/
试试这个:
$('#btnSelected').click(function () {
var name = $("#<%=ddldistrict.ClientID %>").val();
$.ajax({
type: 'post',
contentType: "application/json; charset=utf-8",
url: "reportutil.aspx/LoadMandals",
data: JSON.stringify({ name: name }),
async: false,
success: function (response) {
$("[id*=ddlCustomers]").empty();
var appendData = "<option value=''>--Select--</option>";
for (var i = 0; i < response.d.length; i++) {
if (response.d[i].Name != "") {
appendData += "<option value ='" + response.d[i].ValueFieldName + "'>" + response.d[i].TextFieldName + "</option>";
}
}
$("[id*=ddlCustomers]").append(appenddata1);
},
error: function () { alert("error"); }
});
});