Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Axes(xlCategory).CategoryNames
I am trying to assign labels to the tickmarks on a chart in an Excel module.
I have the following code: label = "all the same" For Each tick In chtObj.Chart.Axes(xlCategory).CategoryNames tick = label Next I am getting an error because of a type mismatch. It appears that chtObj.Chart.Axes(xlCategory).CategoryNames is typed as "Variant/Double". Can anyone help? |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Axes(xlCategory).CategoryNames
Can you set Label to Variant/Double?
"BHatMJ" wrote: I am trying to assign labels to the tickmarks on a chart in an Excel module. I have the following code: label = "all the same" For Each tick In chtObj.Chart.Axes(xlCategory).CategoryNames tick = label Next I am getting an error because of a type mismatch. It appears that chtObj.Chart.Axes(xlCategory).CategoryNames is typed as "Variant/Double". Can anyone help? |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Axes(xlCategory).CategoryNames
The labels are text strings so I need a way of changing CategoryNames (I
think)? "Barb Reinhardt" wrote: Can you set Label to Variant/Double? "BHatMJ" wrote: I am trying to assign labels to the tickmarks on a chart in an Excel module. I have the following code: label = "all the same" For Each tick In chtObj.Chart.Axes(xlCategory).CategoryNames tick = label Next I am getting an error because of a type mismatch. It appears that chtObj.Chart.Axes(xlCategory).CategoryNames is typed as "Variant/Double". Can anyone help? |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Axes(xlCategory).CategoryNames
Thanks for the help. I found syntax that works. (example) chtObj.Chart.Axes(xlCategory).CategoryNames = Range("A1:Z1") "BHatMJ" wrote: The labels are text strings so I need a way of changing CategoryNames (I think)? "Barb Reinhardt" wrote: Can you set Label to Variant/Double? "BHatMJ" wrote: I am trying to assign labels to the tickmarks on a chart in an Excel module. I have the following code: label = "all the same" For Each tick In chtObj.Chart.Axes(xlCategory).CategoryNames tick = label Next I am getting an error because of a type mismatch. It appears that chtObj.Chart.Axes(xlCategory).CategoryNames is typed as "Variant/Double". Can anyone help? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Adjusting the y axes on 2-axes line graphs | Charts and Charting in Excel | |||
Run-time error '1004': Unable to set the CategoryNames property of the Axis class | Excel Programming | |||
Run-time error '1004': Unable to set the CategoryNames property of the Axis class | Excel Programming | |||
Run-time error '1004': Unable to set the CategoryNames property of the Axis class | Excel Programming | |||
Axes(xlCategory).TickLabels problem | Excel Programming |