charts - WPF Charting toolkit change axis interval labels programatically -


i'd programatically change interval of labels on x axis of line chart. thing i've found how in xaml file: https://stackoverflow.com/a/8944925/2302510 , works fine. can hours/days/months etc. need change according interval i'm displaying. user can choose display 1 week, 1 month, 1 year or other given interval , when leaving default overcrowds x axis dates makes quite confusing. advice.

you can assign name axis , call code-behind.

xaml:

<chartingtoolkit:datetimeaxis x:name="xaxis" orientation="x" intervaltype ="hours" interval="1"> 

c#

xaxis.intervaltype = datetimeintervaltype.days; // month, hours xaxis.interval = 1 

Comments

Popular posts from this blog

c++ - Function signature as a function template parameter -

How to call a javascript function after the page loads with a chrome extension? -

algorithm - What are some ways to combine a number of (potentially incompatible) sorted sub-sets of a total set into a (partial) ordering of the total set? -