Solved

Displaying Graphic On and Off

Posted on 2011-09-04
3
238 Views
Last Modified: 2012-05-12
I have this great little chart/graph that both Teylyn and Brad (Byuntd) helped me create (actually, they did most of the creating while I only assembled and did some learning).  I have the graphic on a single worksheet and have linked it into a front end sheet at a reduced size, (via copying the original chart/graphic and a macro that keeps it dynamically updated between worksheets.  Here's my question.  Is there some simple macro code I can use (button activated) that will toggle off and on the graphic (i.e. display it, hide it) on the target worksheet?  And do I load the code into the worksheet or a module?

Thank you in advance,

B.
0
Comment
Question by:Bright01
  • 2
3 Comments
 
LVL 81

Expert Comment

by:byundt
ID: 36481234
You can toggle the visibility of the chart using the following macro in a regular module sheet:

Sub ToggleChartVisibility()
With Worksheets("Target").ChartObjects(1)
    .Visible = Not .Visible
End With
End Sub

Open in new window


Brad
0
 
LVL 81

Accepted Solution

by:
byundt earned 500 total points
ID: 36481240
I updated your sample file with command buttons (Forms toolbar) to run the two macros.

Brad
Adjusting-Graphic-v1--1-Source-t.xlsm
0
 

Author Closing Comment

by:Bright01
ID: 36481333
Brad,

Great work!  Killer App. (as far as you can take an Excel Workbook that is!).

Appreciate the tips, pointers, updates and hard work.

B.
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Getting error in connectionstring with Excel. 30 32
Multiple Open Excel Spreadsheets 12 41
Excel VBA 10 40
And OR formula 5 22
Introduction While answering a recent question (http:/Q_27311462.html), I created an alternative function to the Excel Concatenate() function that you might find useful.  I tested several solutions and share the results in this article as well as t…
How to quickly and accurately populate Word documents with Excel data, charts and images (including Automated Bookmark generation) David Miller (dlmille) Synopsis In this article you’ll learn how to use ExcelToWord! to copy data,charts, shapes …
This Micro Tutorial demonstrate the bugs in Microsoft Excel for Mac with Pivot Charts.
This Micro Tutorial will demonstrate how to use longer labels with horizontal bar charts instead of the vertical column chart.

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question