Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 181
Default xl2002: Position Picture in SeriesCollection

I have a stacked column chart containing several series. I need to position
a different pre-defined image in the center of each series that appears in
the charts.

All images are the same size and small enough to fit into the series, each
image already exists on the sheet, and each image name is sequential (for
series 1 the image name will be "Pic1".)

Any ideas gratefully received.

Trevor Williams
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9,101
Default xl2002: Position Picture in SeriesCollection

Does this code help. You don't need to position the picture, the bars have
fill effects which alow pictures to be inserted into the chart

Sub Macro3()
'
' Macro3 Macro
' Macro recorded 10/19/2007 by Joel
'
'
ActiveSheet.ChartObjects("Chart 1").Activate
ActiveChart.SeriesCollection(2).Select
Selection.Fill.UserPicture PictureFile:= _
"H:\My Documents\My Pictures\abc.jpg", PictureFormat:=xlStretch, _
PicturePlacement:=xlAllFaces
Selection.Fill.Visible = True

End Sub

"Trevor Williams" wrote:

I have a stacked column chart containing several series. I need to position
a different pre-defined image in the center of each series that appears in
the charts.

All images are the same size and small enough to fit into the series, each
image already exists on the sheet, and each image name is sequential (for
series 1 the image name will be "Pic1".)

Any ideas gratefully received.

Trevor Williams

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 181
Default xl2002: Position Picture in SeriesCollection

Hi Joel - thanks for the quick response.
Unfortunately I don't need to 'fill' the series with a picture.

All I need to do is place the picture in the center of the series. (floating
over the top of the series rather than embedded)

Any ideas?

Trevor

"Joel" wrote:

Does this code help. You don't need to position the picture, the bars have
fill effects which alow pictures to be inserted into the chart

Sub Macro3()
'
' Macro3 Macro
' Macro recorded 10/19/2007 by Joel
'
'
ActiveSheet.ChartObjects("Chart 1").Activate
ActiveChart.SeriesCollection(2).Select
Selection.Fill.UserPicture PictureFile:= _
"H:\My Documents\My Pictures\abc.jpg", PictureFormat:=xlStretch, _
PicturePlacement:=xlAllFaces
Selection.Fill.Visible = True

End Sub

"Trevor Williams" wrote:

I have a stacked column chart containing several series. I need to position
a different pre-defined image in the center of each series that appears in
the charts.

All images are the same size and small enough to fit into the series, each
image already exists on the sheet, and each image name is sequential (for
series 1 the image name will be "Pic1".)

Any ideas gratefully received.

Trevor Williams

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9,101
Default xl2002: Position Picture in SeriesCollection

What is the difference??????????
Try clicking the BAR - Format Data Point - Fill Effect - Picture - Select
Picture.

I went looking for the shape of the Bar to try to get the Top and Left
poistion but could not find the object.

"Trevor Williams" wrote:

Hi Joel - thanks for the quick response.
Unfortunately I don't need to 'fill' the series with a picture.

All I need to do is place the picture in the center of the series. (floating
over the top of the series rather than embedded)

Any ideas?

Trevor

"Joel" wrote:

Does this code help. You don't need to position the picture, the bars have
fill effects which alow pictures to be inserted into the chart

Sub Macro3()
'
' Macro3 Macro
' Macro recorded 10/19/2007 by Joel
'
'
ActiveSheet.ChartObjects("Chart 1").Activate
ActiveChart.SeriesCollection(2).Select
Selection.Fill.UserPicture PictureFile:= _
"H:\My Documents\My Pictures\abc.jpg", PictureFormat:=xlStretch, _
PicturePlacement:=xlAllFaces
Selection.Fill.Visible = True

End Sub

"Trevor Williams" wrote:

I have a stacked column chart containing several series. I need to position
a different pre-defined image in the center of each series that appears in
the charts.

All images are the same size and small enough to fit into the series, each
image already exists on the sheet, and each image name is sequential (for
series 1 the image name will be "Pic1".)

Any ideas gratefully received.

Trevor Williams

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 181
Default xl2002: Position Picture in SeriesCollection

The difference should be obvious, but as you asked... If you fill the series
with an image the image becomes the series, and stretches , or stacks in the
series (creating more than one image). If you position a floating image over
the series the image remains the original size, shows only as one image, can
be controlled easier using VB, and the series below the image remains in the
format applied.

Thanks for trying.

Trevor



"Joel" wrote:

What is the difference??????????
Try clicking the BAR - Format Data Point - Fill Effect - Picture - Select
Picture.

I went looking for the shape of the Bar to try to get the Top and Left
poistion but could not find the object.

"Trevor Williams" wrote:

Hi Joel - thanks for the quick response.
Unfortunately I don't need to 'fill' the series with a picture.

All I need to do is place the picture in the center of the series. (floating
over the top of the series rather than embedded)

Any ideas?

Trevor

"Joel" wrote:

Does this code help. You don't need to position the picture, the bars have
fill effects which alow pictures to be inserted into the chart

Sub Macro3()
'
' Macro3 Macro
' Macro recorded 10/19/2007 by Joel
'
'
ActiveSheet.ChartObjects("Chart 1").Activate
ActiveChart.SeriesCollection(2).Select
Selection.Fill.UserPicture PictureFile:= _
"H:\My Documents\My Pictures\abc.jpg", PictureFormat:=xlStretch, _
PicturePlacement:=xlAllFaces
Selection.Fill.Visible = True

End Sub

"Trevor Williams" wrote:

I have a stacked column chart containing several series. I need to position
a different pre-defined image in the center of each series that appears in
the charts.

All images are the same size and small enough to fit into the series, each
image already exists on the sheet, and each image name is sequential (for
series 1 the image name will be "Pic1".)

Any ideas gratefully received.

Trevor Williams



  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,489
Default xl2002: Position Picture in SeriesCollection

Hi,

Can you make use of this technique for custom markers?
http://peltiertech.com/Excel/ChartsH...omMarkers.html

Cheers
Andy
--

Andy Pope, Microsoft MVP - Excel
http://www.andypope.info
"Trevor Williams" wrote in
message ...
Hi Joel - thanks for the quick response.
Unfortunately I don't need to 'fill' the series with a picture.

All I need to do is place the picture in the center of the series.
(floating
over the top of the series rather than embedded)

Any ideas?

Trevor

"Joel" wrote:

Does this code help. You don't need to position the picture, the bars
have
fill effects which alow pictures to be inserted into the chart

Sub Macro3()
'
' Macro3 Macro
' Macro recorded 10/19/2007 by Joel
'
'
ActiveSheet.ChartObjects("Chart 1").Activate
ActiveChart.SeriesCollection(2).Select
Selection.Fill.UserPicture PictureFile:= _
"H:\My Documents\My Pictures\abc.jpg", PictureFormat:=xlStretch,
_
PicturePlacement:=xlAllFaces
Selection.Fill.Visible = True

End Sub

"Trevor Williams" wrote:

I have a stacked column chart containing several series. I need to
position
a different pre-defined image in the center of each series that appears
in
the charts.

All images are the same size and small enough to fit into the series,
each
image already exists on the sheet, and each image name is sequential
(for
series 1 the image name will be "Pic1".)

Any ideas gratefully received.

Trevor Williams


  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,582
Default xl2002: Position Picture in SeriesCollection

I was going to suggest this, where you keep the columns, but also include
line or XY chart series with X values calculated to position a marker in the
middle of a column. If it is a clustered column chart, you'll need the XY
approach:

http://peltiertech.com/Excel/Charts/...olAndLine.html

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


"Andy Pope" wrote in message
...
Hi,

Can you make use of this technique for custom markers?
http://peltiertech.com/Excel/ChartsH...omMarkers.html

Cheers
Andy
--

Andy Pope, Microsoft MVP - Excel
http://www.andypope.info
"Trevor Williams" wrote in
message ...
Hi Joel - thanks for the quick response.
Unfortunately I don't need to 'fill' the series with a picture.

All I need to do is place the picture in the center of the series.
(floating
over the top of the series rather than embedded)

Any ideas?

Trevor

"Joel" wrote:

Does this code help. You don't need to position the picture, the bars
have
fill effects which alow pictures to be inserted into the chart

Sub Macro3()
'
' Macro3 Macro
' Macro recorded 10/19/2007 by Joel
'
'
ActiveSheet.ChartObjects("Chart 1").Activate
ActiveChart.SeriesCollection(2).Select
Selection.Fill.UserPicture PictureFile:= _
"H:\My Documents\My Pictures\abc.jpg", PictureFormat:=xlStretch,
_
PicturePlacement:=xlAllFaces
Selection.Fill.Visible = True

End Sub

"Trevor Williams" wrote:

I have a stacked column chart containing several series. I need to
position
a different pre-defined image in the center of each series that
appears in
the charts.

All images are the same size and small enough to fit into the series,
each
image already exists on the sheet, and each image name is sequential
(for
series 1 the image name will be "Pic1".)

Any ideas gratefully received.

Trevor Williams




  #8   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,600
Default xl2002: Position Picture in SeriesCollection

Did you also look at the possibility of sizing the image to x units. As it
seems you are using stacked columns it would be possible to have an
additional series of up to x units (one fixed size image), slotted into the
most appropriate series order, with similar value (x) deducted from an
adjacent series.

Otherwise you could do pretty much as you ask, ie place your respective
images over columns, perhaps all at same height in a row or to vertical
centers of the columns (bit more work). The tedious bit is working our the
'inner' coordinates of the plot area (ticklabels are in the 'outer').

Hopefully though one of Jon's method will have worked for you.

Regards,
Peter T


"Trevor Williams" wrote in
message ...
The difference should be obvious, but as you asked... If you fill the

series
with an image the image becomes the series, and stretches , or stacks in

the
series (creating more than one image). If you position a floating image

over
the series the image remains the original size, shows only as one image,

can
be controlled easier using VB, and the series below the image remains in

the
format applied.

Thanks for trying.

Trevor



"Joel" wrote:

What is the difference??????????
Try clicking the BAR - Format Data Point - Fill Effect - Picture -

Select
Picture.

I went looking for the shape of the Bar to try to get the Top and Left
poistion but could not find the object.

"Trevor Williams" wrote:

Hi Joel - thanks for the quick response.
Unfortunately I don't need to 'fill' the series with a picture.

All I need to do is place the picture in the center of the series.

(floating
over the top of the series rather than embedded)

Any ideas?

Trevor

"Joel" wrote:

Does this code help. You don't need to position the picture, the

bars have
fill effects which alow pictures to be inserted into the chart

Sub Macro3()
'
' Macro3 Macro
' Macro recorded 10/19/2007 by Joel
'
'
ActiveSheet.ChartObjects("Chart 1").Activate
ActiveChart.SeriesCollection(2).Select
Selection.Fill.UserPicture PictureFile:= _
"H:\My Documents\My Pictures\abc.jpg",

PictureFormat:=xlStretch, _
PicturePlacement:=xlAllFaces
Selection.Fill.Visible = True

End Sub

"Trevor Williams" wrote:

I have a stacked column chart containing several series. I need

to position
a different pre-defined image in the center of each series that

appears in
the charts.

All images are the same size and small enough to fit into the

series, each
image already exists on the sheet, and each image name is

sequential (for
series 1 the image name will be "Pic1".)

Any ideas gratefully received.

Trevor Williams



  #9   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 181
Default xl2002: Position Picture in SeriesCollection

Hi Jon

thanks for your response. I've been checking out your site for some time.
I'll give it a go.

Is there no way to work out the size of each Points with the SeriesCollection?
Also, is there a way to obtain the length of the X axis? I need to draw a
rectangle to match it.

Thanks again.

Trevor



"Jon Peltier" wrote:

I was going to suggest this, where you keep the columns, but also include
line or XY chart series with X values calculated to position a marker in the
middle of a column. If it is a clustered column chart, you'll need the XY
approach:

http://peltiertech.com/Excel/Charts/...olAndLine.html

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


"Andy Pope" wrote in message
...
Hi,

Can you make use of this technique for custom markers?
http://peltiertech.com/Excel/ChartsH...omMarkers.html

Cheers
Andy
--

Andy Pope, Microsoft MVP - Excel
http://www.andypope.info
"Trevor Williams" wrote in
message ...
Hi Joel - thanks for the quick response.
Unfortunately I don't need to 'fill' the series with a picture.

All I need to do is place the picture in the center of the series.
(floating
over the top of the series rather than embedded)

Any ideas?

Trevor

"Joel" wrote:

Does this code help. You don't need to position the picture, the bars
have
fill effects which alow pictures to be inserted into the chart

Sub Macro3()
'
' Macro3 Macro
' Macro recorded 10/19/2007 by Joel
'
'
ActiveSheet.ChartObjects("Chart 1").Activate
ActiveChart.SeriesCollection(2).Select
Selection.Fill.UserPicture PictureFile:= _
"H:\My Documents\My Pictures\abc.jpg", PictureFormat:=xlStretch,
_
PicturePlacement:=xlAllFaces
Selection.Fill.Visible = True

End Sub

"Trevor Williams" wrote:

I have a stacked column chart containing several series. I need to
position
a different pre-defined image in the center of each series that
appears in
the charts.

All images are the same size and small enough to fit into the series,
each
image already exists on the sheet, and each image name is sequential
(for
series 1 the image name will be "Pic1".)

Any ideas gratefully received.

Trevor Williams





  #10   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,582
Default xl2002: Position Picture in SeriesCollection

ActiveChart.SeriesCollection(1).Points.Count
ActiveChart.Axes(xlCategory, xlPrimary).Width

There is some information about using shapes and VBA in Excel charts he

http://peltiertech.com/Excel/Charts/VBAdraw.html

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


"Trevor Williams" wrote in
message ...
Hi Jon

thanks for your response. I've been checking out your site for some time.
I'll give it a go.

Is there no way to work out the size of each Points with the
SeriesCollection?
Also, is there a way to obtain the length of the X axis? I need to draw a
rectangle to match it.

Thanks again.

Trevor



"Jon Peltier" wrote:

I was going to suggest this, where you keep the columns, but also include
line or XY chart series with X values calculated to position a marker in
the
middle of a column. If it is a clustered column chart, you'll need the XY
approach:

http://peltiertech.com/Excel/Charts/...olAndLine.html

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


"Andy Pope" wrote in message
...
Hi,

Can you make use of this technique for custom markers?
http://peltiertech.com/Excel/ChartsH...omMarkers.html

Cheers
Andy
--

Andy Pope, Microsoft MVP - Excel
http://www.andypope.info
"Trevor Williams" wrote in
message ...
Hi Joel - thanks for the quick response.
Unfortunately I don't need to 'fill' the series with a picture.

All I need to do is place the picture in the center of the series.
(floating
over the top of the series rather than embedded)

Any ideas?

Trevor

"Joel" wrote:

Does this code help. You don't need to position the picture, the
bars
have
fill effects which alow pictures to be inserted into the chart

Sub Macro3()
'
' Macro3 Macro
' Macro recorded 10/19/2007 by Joel
'
'
ActiveSheet.ChartObjects("Chart 1").Activate
ActiveChart.SeriesCollection(2).Select
Selection.Fill.UserPicture PictureFile:= _
"H:\My Documents\My Pictures\abc.jpg",
PictureFormat:=xlStretch,
_
PicturePlacement:=xlAllFaces
Selection.Fill.Visible = True

End Sub

"Trevor Williams" wrote:

I have a stacked column chart containing several series. I need to
position
a different pre-defined image in the center of each series that
appears in
the charts.

All images are the same size and small enough to fit into the
series,
each
image already exists on the sheet, and each image name is
sequential
(for
series 1 the image name will be "Pic1".)

Any ideas gratefully received.

Trevor Williams








  #11   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 181
Default xl2002: Position Picture in SeriesCollection

Thanks again Jon

I can't believe how easy it was to use custom series markers!

Trevor

"Jon Peltier" wrote:

ActiveChart.SeriesCollection(1).Points.Count
ActiveChart.Axes(xlCategory, xlPrimary).Width

There is some information about using shapes and VBA in Excel charts he

http://peltiertech.com/Excel/Charts/VBAdraw.html

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


"Trevor Williams" wrote in
message ...
Hi Jon

thanks for your response. I've been checking out your site for some time.
I'll give it a go.

Is there no way to work out the size of each Points with the
SeriesCollection?
Also, is there a way to obtain the length of the X axis? I need to draw a
rectangle to match it.

Thanks again.

Trevor



"Jon Peltier" wrote:

I was going to suggest this, where you keep the columns, but also include
line or XY chart series with X values calculated to position a marker in
the
middle of a column. If it is a clustered column chart, you'll need the XY
approach:

http://peltiertech.com/Excel/Charts/...olAndLine.html

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


"Andy Pope" wrote in message
...
Hi,

Can you make use of this technique for custom markers?
http://peltiertech.com/Excel/ChartsH...omMarkers.html

Cheers
Andy
--

Andy Pope, Microsoft MVP - Excel
http://www.andypope.info
"Trevor Williams" wrote in
message ...
Hi Joel - thanks for the quick response.
Unfortunately I don't need to 'fill' the series with a picture.

All I need to do is place the picture in the center of the series.
(floating
over the top of the series rather than embedded)

Any ideas?

Trevor

"Joel" wrote:

Does this code help. You don't need to position the picture, the
bars
have
fill effects which alow pictures to be inserted into the chart

Sub Macro3()
'
' Macro3 Macro
' Macro recorded 10/19/2007 by Joel
'
'
ActiveSheet.ChartObjects("Chart 1").Activate
ActiveChart.SeriesCollection(2).Select
Selection.Fill.UserPicture PictureFile:= _
"H:\My Documents\My Pictures\abc.jpg",
PictureFormat:=xlStretch,
_
PicturePlacement:=xlAllFaces
Selection.Fill.Visible = True

End Sub

"Trevor Williams" wrote:

I have a stacked column chart containing several series. I need to
position
a different pre-defined image in the center of each series that
appears in
the charts.

All images are the same size and small enough to fit into the
series,
each
image already exists on the sheet, and each image name is
sequential
(for
series 1 the image name will be "Pic1".)

Any ideas gratefully received.

Trevor Williams







Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Insert, position, and resize a picture w/ Macro John Excel Discussion (Misc queries) 1 July 10th 07 07:21 PM
Picture objects and text boxes change position Tyler H Charts and Charting in Excel 1 June 16th 07 04:31 PM
How to keep picture position for different versions of Excel? Simon Kwong Excel Discussion (Misc queries) 2 April 15th 07 03:08 AM
Position Picture with macro G Setting up and Configuration of Excel 1 November 28th 05 08:25 PM
Position of CellCursor on Screen (absolute position) [email protected] Excel Programming 1 November 23rd 05 03:23 AM


All times are GMT +1. The time now is 11:41 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"