Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a VB app that uses a VBA script to create a sheet with data and then
another sheet with a chart representing that data in graphical form. The sheet with the data on it has formulas that are run on a subset of the data. Currently these formulas are hardcoded with the range to calculate from. But I need to change it so the user can select a starting and ending point from the chart (on the other page) that the formulas will use to calculate from. I am new to Office scripting so any ideas on how to do this (if it's even possible) would be helpful. Thanks. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
You can determine which chart element is selected using the Selection
object, but it's tedious to do this to get more than one selection, because you have to make the user stop, select something else. then click something to continue the code. You can also use chart events to respond to mouse actions in the chart. It's a bit tricky, especially if you've done little programming, but here's a reasonably straightforward tutorial: http://www.computorcompanion.com/LPMArticle.asp?ID=221 I've used this technique to do much the same as you, let the user easily select the first and last point for detailed analysis. - Jon ------- Jon Peltier, Microsoft Excel MVP Tutorials and Custom Solutions Peltier Technical Services, Inc. - http://PeltierTech.com _______ "Nathan Smith" wrote in message ... I have a VB app that uses a VBA script to create a sheet with data and then another sheet with a chart representing that data in graphical form. The sheet with the data on it has formulas that are run on a subset of the data. Currently these formulas are hardcoded with the range to calculate from. But I need to change it so the user can select a starting and ending point from the chart (on the other page) that the formulas will use to calculate from. I am new to Office scripting so any ideas on how to do this (if it's even possible) would be helpful. Thanks. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
VBA Code User Range Selection | Excel Discussion (Misc queries) | |||
sheet selection via user click (yez) | Excel Programming | |||
type of selection if selection is chart | Excel Programming | |||
refer to user selection | Excel Programming | |||
User selection | Excel Programming |