'Excel ignore empty cell in data for a chart

I am using Excel 365. I have a data sheet with no formulas - the data is input manually. A chart is then created using that data but if there are any empty cells the chart defaults to 0 instead of simply ending at the last piece of data that was inputted. I have Googled this and know I solved the problem about 2 years ago on another chart but I can't remember what I did. It certainly wasn't a formula, as I am not using any formulas in the database. I have gone into Select Data and Hidden Data and that is on Zero but the problem still exists. Can someone help me please? enter image description here



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source