K
Kenny Thompson
Hi,
I am trying to create a line graph using a Microsoft VB Express module.
I can get the grpah to appear with labels etc however I cannot change the
chart type to line(or any other type).
Below is the segment of code I have to display the graph:
With oBook.ActiveSheet.ChartObjects.Add _
(Left:=100, Width:=375, Top:=75, Height:=225)
.Chart.ChartWizard(Source:=oBook.ActiveSheet.Range("C4:C10"),
Gallery:=xlLine, Title:="TEST", _
ValueTitle:="# of trans", CategoryTitle:="tps")
End With
The error I get is " Name 'xlLine' is not declared.
What I dont understand is that the Title,ValueTitle,CategoryTitle properties
all work fine but I get the error on the Gallery property.
Any suggestions appreciated.
I am trying to create a line graph using a Microsoft VB Express module.
I can get the grpah to appear with labels etc however I cannot change the
chart type to line(or any other type).
Below is the segment of code I have to display the graph:
With oBook.ActiveSheet.ChartObjects.Add _
(Left:=100, Width:=375, Top:=75, Height:=225)
.Chart.ChartWizard(Source:=oBook.ActiveSheet.Range("C4:C10"),
Gallery:=xlLine, Title:="TEST", _
ValueTitle:="# of trans", CategoryTitle:="tps")
End With
The error I get is " Name 'xlLine' is not declared.
What I dont understand is that the Title,ValueTitle,CategoryTitle properties
all work fine but I get the error on the Gallery property.
Any suggestions appreciated.