ASE Home Page Products Download Purchase Support About ASE
ChartDirector Support
Forum HomeForum Home   SearchSearch

Message ListMessage List     Post MessagePost Message

  How to make chart re-sizable with browser size
Posted by Dilip Agarwal on Apr-17-2014 17:13
Hi, could you please tell me how can I make charts re-sizable with browser i.e, if browser
size change then chart image size also change.

  Re: How to make chart re-sizable with browser size
Posted by Dilip Agarwal on Apr-17-2014 21:00
Looks Fixed by below code.

$(window).resize(function() {
  var width = $(window).width();
  var height = $(window).height();
  viewer = JsChartViewer.get('<%=viewer.Id%>');

  viewer.setCustomAttr("width",width)
  viewer.setCustomAttr("height",height*.90)
  viewer.setCustomAttr("zoomState", "F");
  viewer.partialUpdate();
})

Is this correct way.