# Bar chart min and max value

**URL:** <https://community.appfarm.io/t/bar-chart-min-and-max-value/1482>\
**Category:** Ask the community\
**Created:** [November 1, 2024, 9:28am UTC](https://community.appfarm.io/t/bar-chart-min-and-max-value/1482 "2024-11-01T09:28:08Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Siri](https://dub1.discourse-cdn.com/flex013/user_avatar/community.appfarm.io/siri/32/1368_2.png) [@Siri](https://community.appfarm.io/u/Siri)\
**Post date:** [November 1, 2024, 9:28am UTC](https://community.appfarm.io/t/bar-chart-min-and-max-value/1482/1 "2024-11-01T09:28:08Z")

</div>

I have an object class called Invoice history that consists of the properties Amount (float) and Completed date (DateTime). I have plotted Invoice history in a bar chart where data is grouped by month and the amount is summed. A filter ensures that only one year at a time is shown. Is there a way I can make the bar chart show all the months of the year, even though some months do not contain data?

In the screenshot here I would for example like to see November and December:  
 ![image](https://europe1.discourse-cdn.com/flex013/uploads/appfarm/original/2X/e/e6de3406f3b39a455d170f6c14c07d4b68596304.png)

I tried adding an app variable that finds the last day of the current year as input for max value on the X-axis (and same method with min), but the chart then shows numbers in stead of month names and one month too many.

![image](https://europe1.discourse-cdn.com/flex013/uploads/appfarm/original/2X/4/4417d15659f433bcee9efe60f2e3d77b05d6c262.png)

---

<div class="post-metadata">

**Author:** ![kristian](https://dub1.discourse-cdn.com/flex013/user_avatar/community.appfarm.io/kristian/32/58_2.png) [@kristian](https://community.appfarm.io/u/kristian)\
**Post date:** [November 6, 2024, 1:12pm UTC](https://community.appfarm.io/t/bar-chart-min-and-max-value/1482/2 "2024-11-06T13:12:32Z")

</div>

Hi!

I believe you are pretty close here!

Try the following: Category Axis (X): Choose **Axis type = Datetime** , and then set the Min and/or Max value to a datetime (e.g. using Now.valueprocessor(endofyear), Now.valueprocessor(to months back, startofmonth))

---

<div class="post-metadata">

**Author:** ![Sondre](https://dub1.discourse-cdn.com/flex013/user_avatar/community.appfarm.io/sondre/32/105_2.png) [@Sondre](https://community.appfarm.io/u/Sondre)\
**Post date:** [April 29, 2025, 3:50pm UTC](https://community.appfarm.io/t/bar-chart-min-and-max-value/1482/3 "2025-04-29T15:50:30Z")

</div>

Hi,

I tried adding the same dates as the Bar Chart is filtered on, and axis type Datetime

 ![image](https://europe1.discourse-cdn.com/flex013/uploads/appfarm/original/2X/3/32a535e1395af3f05609c1791f0e8ed38a7f023a.png)

Same result as Siri

 ![image](https://europe1.discourse-cdn.com/flex013/uploads/appfarm/original/2X/8/8a52457bafaaebc5f9f5d7ff8163c4eca34c0fbe.png)

This is the advanced bar chart and i also tried with extend to min value toggled on without success.
