Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi, I am looking to update a chart at the end of a working routine. Each time
a new line is add and I only want the final four row. Here is what I have done so far with everything I found out. Sub MACRO1() #line ok#Set chartrange = Range("D5").End(xlDown).Offset(-3, -3).Resize(4, 4).Activate Here is where I got problems Sheets("graph par qty").Select ActiveChart.SetSourceData Source:=chartrange, PlotBy:=xlColumns End Sub -- Mathieu |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Change the first statement to
Set chartrange = Worksheets("Sheet Name").Range("D5").End(xlDown).Offset(-3, -3).Resize(4, 4) If this doesn't solve the problem, post back with a clearer description of what didn't work. - Jon ------- Jon Peltier, Microsoft Excel MVP Tutorials and Custom Solutions http://PeltierTech.com _______ "Mathieu" wrote in message ... Hi, I am looking to update a chart at the end of a working routine. Each time a new line is add and I only want the final four row. Here is what I have done so far with everything I found out. Sub MACRO1() #line ok#Set chartrange = Range("D5").End(xlDown).Offset(-3, -3).Resize(4, 4).Activate Here is where I got problems Sheets("graph par qty").Select ActiveChart.SetSourceData Source:=chartrange, PlotBy:=xlColumns End Sub -- Mathieu |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thank you so much!!!, that is working. I am jsut beginning how to work with
vba and from what I discover, I should have learn that before. I will be clearer next time! Mathieu "Jon Peltier" wrote: Change the first statement to Set chartrange = Worksheets("Sheet Name").Range("D5").End(xlDown).Offset(-3, -3).Resize(4, 4) If this doesn't solve the problem, post back with a clearer description of what didn't work. - Jon ------- Jon Peltier, Microsoft Excel MVP Tutorials and Custom Solutions http://PeltierTech.com _______ "Mathieu" wrote in message ... Hi, I am looking to update a chart at the end of a working routine. Each time a new line is add and I only want the final four row. Here is what I have done so far with everything I found out. Sub MACRO1() #line ok#Set chartrange = Range("D5").End(xlDown).Offset(-3, -3).Resize(4, 4).Activate Here is where I got problems Sheets("graph par qty").Select ActiveChart.SetSourceData Source:=chartrange, PlotBy:=xlColumns End Sub -- Mathieu |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Graph and Input box for Date Range | Charts and Charting in Excel | |||
How do I graph data daily as a line graph across a calendar format | Charts and Charting in Excel | |||
Input data for graph | Excel Programming | |||
How do I input info from sheet to a graph in Excel? | Charts and Charting in Excel | |||
How do I add input data in the input ranges in drop down boxes. | Excel Discussion (Misc queries) |