Results 1 to 6 of 6

How to write VBA code that waits for the user to select a chart?

Threaded View

  1. #6
    Registered User
    Join Date
    08-06-2013
    Location
    the boonies
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to write VBA code that waits for the user to select a chart?

    Let me try to explain more clearly...

    Once I execute the code, at a certain point I want it to pause until it receives a mouse click on a chart from the user (which would activate that chart), and then proceed with the rest of the instructions.

    I've done a fair bit of research in the last two evenings, and have not yet found an example that shows code this general. It's always "exit sub if no chart was selected prior to executing the sub", or "set mychart equal to a known chart, and activate it (if not already active) before proceeding." In my case, I do not want to hardwire a known chart in the code, but rather, wait for the user to select a chart with a mouse click, and use that action as the chart selection to pass to "ActiveChart".

    Again, if you have a coding example of this type of thing, or you know this to be beyond the capabilities of VBA, please post!

    Cheers,
    g
    Last edited by geophysicist; 08-23-2013 at 02:58 AM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 0
    Last Post: 06-11-2013, 05:14 PM
  2. How do i code a VBA to ask the user to select which file to use
    By kenadams378 in forum Excel Programming / VBA / Macros
    Replies: 17
    Last Post: 05-16-2012, 07:26 PM
  3. Can't write code to find last data row in excel user form
    By stevegrobertson in forum Excel General
    Replies: 8
    Last Post: 02-24-2012, 10:16 PM
  4. Code to prevent user to Select COLUMNS but allow to select ROWS
    By tengrosita in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-05-2011, 03:46 AM
  5. Create chart where user select part of data
    By Endorphin in forum Excel Charting & Pivots
    Replies: 5
    Last Post: 10-23-2008, 06:50 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1