cross hatching and pie chart

  • Thread starter Cenk Ursavas via OfficeKB.com
  • Start date
C

Cenk Ursavas via OfficeKB.com

I have two excel questions:
First one is about cross hatching:I am using asp to do cross hatching but
there is a problem when the two hatchings overlap.One hatch stays behind
the other:
http://www.imlab.psu.edu/forest/gr.gif
is there a way to make the hatches transperant?

My second question is about pie charts: I am also displaying pie charts to
the user via asp. I want to get rid of the black box around the pie chart:
http://www.imlab.psu.edu/thesis/1.gif
or make the chart pie itself larger in the box,is there a way to do this?
Is there a way to display the CategoryName instead of the percentage?
"crt.Chart.SeriesCollection(3).DataLabels.ShowCategoryName = True"
does not seem to work!!!!

Thanks for the answers
cengo
 
J

Jon Peltier

Cengo -

If you're using ASP, it's not exactly Excel, but here goes:

1. The cross hatching will look ugly, and you won't be able to make it partially
transparent, no matter what. Transparency in Excel chart fills has not progressed
since Excel 5.

2. To remove the box from an Excel chart:

crt.Chart.ChartArea.Border.LineStyle = 0

To reposition and resize the pie in an Excel chart:

With crt.Chart.PlotArea
.Left = 72
.Top = 21
.Width = 172
.Height = 170
End With

The values are in points, but I wonder if the OWC uses pixels.

To change the data labels:

crt.Chart.SeriesCollection(3).DataLabels.Type = xlDataLabelsShowLabel

or use 4 in place of xlDataLabelsShowLabel.

Here's a handy tip. Even though you're not working in Excel, the chart object models
are similar. Use a combination of Excel's macro recorder, and the object browser in
the platform within which you're developing, to figure out the appropriate syntax.

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Peltier Technical Services
Tutorials and Custom Solutions
http://PeltierTech.com/
_______
 
C

Cenk Ursavas via OfficeKB.com

Thanks for the responses,
So there is no way I can do cross-hatching in excel with transparency??Is
there any other graph I can do which is kind of close to cross-hatching?
I removed the box around the excel pie chart but I have a problem:
"crt.Chart.ApplyDataLabels (xlDataLabelsShowLabelAndPercent)" works but
"crt.Chart.ApplyDataLabels (xlDataLabelsShowValue)" does not work!!So i can
not show labels or the values...Why is that also "crt.Chart.HasDataTable =
True" works for line graph but does not work for a pie chart??
Thanks for the answers
cengo
 
J

Jon Peltier

Cengo -

The cross hatching is an old thing anyway, from the old days of dot matrix. Now most
of the patterns are so small when printed, they just look like a lighter version of
the color.

"crt.Chart.ApplyDataLabels (xlDataLabelsShowValue)" worked for me in a pie chart.

Data Tables are only available in a limited few chart types, like Line, Column,
Area, and I think Bar charts.

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Peltier Technical Services
Tutorials and Custom Solutions
http://PeltierTech.com/
_______
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top