Is it possible to drag and drop the shape of graphs in Excel?
I'm thinking something along the lines of:
-if I click and hold the graph I can drag it up and down
-if I click on a point on the graph and then click and hold on another point, I will drag an interval of the graph up and down
No. What you are asking for is "Interactive charting". The Excel VBA charting interface draws the entire chart based the parameters you define for it. It doesn't have an interface to manipulate the individual components of the chart thru VBA. (Something like move line vertice to new point). In addition, the points of the graph are based on spreadsheet values. So it would have to detect your mouse events over the chart, convert those movements to the scale used in the chart to reverse calculate a value and then change the associated cell in the spreadsheet. And then a graph repaint of the entire chart would be requested. This total repaint would look pretty choppy.
Related
I have a bar graph as seen below, I need to change the colour of all the bars to let's say green.
Currently the only way I have been able to find to do this is click each individual date and then the fill bucket green as excel doesn't allow you to CTRL + Click multiple elements. Is there a way to change the colour of all the bars shown in one go?
Worth mentioning I can not change the colours by creating a "values table" as the workbook is locked and I have to do this for several different graphs.
That's happening because you have created the chart using every date as an individual serie. I suggest to use the "Switch Row/Column" option and became all the dates as a unique serie, so all the bars will have the same color.
In the other hand if you need to keep the chart as you shown on the picture shared, is possible to change every bar at once but just using a VBA code.
I have a chart that I am using to keep track of weekly data. It is a Pivot table with an attached graph. Every week when I refresh the data the chart moves back to the following picture.
Graph
With the Data labels shoved inside of the bottom of the chart. I Spend a bit of time every week moving all of them back down. I would like to anchor them with the upper right corner attaching to the bottom axis. The only placement option in the Pivot chart are Center, Inside End, Inside Base, Outside end. I am using inside base to get the picture I mentioned.
Here is what I change it to each week. As you can see I drag all of them down individually and try to get them to line up as best as I can by hand. But they are never perfect.
I have finally found my problem, The issue was I was using Data Labels and not axis labels.
If you are having this problem go Pivotchart tools > Design > Add chart Element > Axes > Primary Horizontal.
I am working with a pie chart whose data labels are added using the best fit property. Most of those labels are placed by Excel inside the pie, but some of them are placed outside.
Because of some series colors are so strong, the data labels had to be defined as white. Of course, the labels placed outside the pie wont be visible if I don't manually change their color (to black, for instance)
What I am trying to do is to conditionally change the label's color according to where Excel placed it (white inside the pie, black outside it), as in the following image:
I have been searching for a solution, but it seems that nobody had a similar problem.
Does anyone know if Excel allows this or does someone know a trick to bypass it?
There is a way to do this in Excel.
When you click on the chart, and go to Layout under Chart Tools.
Once there, go to Data Labels.
When you click on that, it will display a drop-down menu. At the bottom of the menu, click on More Data Label Options.
It will pull up a new window. On the sidebar of the new window, click on Number.
Then, under Category click on Custom.
In the textbox shown under Format Code, type in [Black][<0.05]0%;[White][>=0.05]0%
Click Add.
It should format the numbers outside the pie chart in your example black, and the numbers inside the pie white. If you had different data, you could format it the same, but you would have to change the number in the brackets after the color to the number one higher than number outside of the pie. It would be like this: [Black][<(number one higher than number outside of the pie)]0%;[White][>=(number one higher than number outside of the pie)]0%
Screenshot of Pie Chart Formatting
Source:
http://chandoo.org/wp/2009/01/29/colors-in-excel-chart-labels-trick/
When I insert one chart in excel, the generated chart will always on the top of the data. However, if I want to select some range of my data to the chart, I usually have to drag the chart away from the top of data for locating the cursor on them.
My question: is there any simple and quick way to switch to focus on one of the data and the chart while hiding the other?
Not a perfect answer, but you can adjust the transparency of the fill of the chart object. Then, click on a cell and use the arrow keys to select the cells of interest behind the chart ...
I'm looking to set up a scroll bar in Excel that corresponds to what set of data I use for a chart. I have built a 2-value doughnut chart that acts as a percentage gauge (green section is completed and grey is 100% minus the completed part).
I want to be able to choose what month's data I use for this chart using the scroll bar. All I can seem to find online is how to modify the number of rows and columns that are displayed on a graph rather than actually using the scroller to pick what data to display.
In addition, how would I make it default to the current month? Any help would be appreciated!
For anyone that is looking for a similar solution, I have figured it out. It works with something called a dynamic range. Use the value of the scrollbar to determine the offset of rows (pick which row of data to use). Then link that dynamic range to your chart in place of where you would select the data.