Then, choose Module from the Insert menu and enter the macro into the module. To enter this macro, press + to open the Visual Basic Editor (VBE). Dim cht As ChartObject For Each cht In ActiveSheet.ChartObjects cht.Height = Application.InchesToPoints(2) cht.Width = Application.InchesToPoints(4) Next End Sub The following macro resizes all of the charts on the active sheet to two inches high and four inches wide (relative to the printed page, not what you see on screen): Sub ResizeCharts() 'Make all charts on active sheet uniform size. That was easy enough, but if you repeat this process often, you might want to use a macro to automate the process. That way, you don't have to repeat this particular task several times-once is enough! (To align the charts, you can use the Align options in the Arrange group.)
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |