Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Old October 9th 09, 10:13 AM posted to microsoft.public.excel.programming
external usenet poster
 
First recorded activity by ExcelBanter: Jan 2010
Posts: 6
Default Object size by copy/paste is different between Office 2003 and 200

Currently we are working on an add-in for Excel/PowerPoint/Word using Office
PIA(XP), the workflow is like this:

1) When the target application is Excel, we write our results directly into
Excel.Cell
2) When the target application is Word / PowerPoint, we first write the
results into Excel.Cell, then copy-paste the Excel.Range into Word/PowerPoint
as an static object via CLIPBOARD, but here we met a problem as described
below.

We want to control the "size" of the copy-paste result, we find that we can
get the original size from Excel.Range.Width and Excel.Range.Height. For
paste method, we use
PowerPoint.Slide.Application.ActiveWindow.View.Pas teSpecial()
function(PowerPoint, similar for Word). , the return value is the
object(PasteElement) that pasted into Word/PowerPoint and its size could be
manipulated by PasteElement.Width and PasteElement.Height property.
Since we want the result has the 100% ratio of the original one, so we
assign original size to PasteElement.Width and PasteElement.Height, but we
have different behavior in 2003 and 2007 when we test this value from Office
GUI.

In 2007, the final size ratio is 99% which is slightly different from target
value, but In 2003, the final size ratio is 95% of the original one which is
not acceptable for us, so I have 2 questions:

1. Since the code is same for Office 2003 and 2007, why there is such
difference?

2. Is copy/paste a good way to transfer data between different office
application(Excel - PowerPoint / Word)?

Does anyone know about this? Thanks!

  #2   Report Post  
Old October 9th 09, 11:26 AM posted to microsoft.public.excel.programming
external usenet poster
 
First recorded activity by ExcelBanter: Jul 2006
Posts: 3,355
Default Object size by copy/paste is different between Office 2003 and 200

I've had to change a registry setting so that Excel objects wouldn't resize
in PowerPoint.

http://support.microsoft.com/kb/300523

Might that be your problem?

"fmamstr" wrote:

Currently we are working on an add-in for Excel/PowerPoint/Word using Office
PIA(XP), the workflow is like this:

1) When the target application is Excel, we write our results directly into
Excel.Cell
2) When the target application is Word / PowerPoint, we first write the
results into Excel.Cell, then copy-paste the Excel.Range into Word/PowerPoint
as an static object via CLIPBOARD, but here we met a problem as described
below.

We want to control the "size" of the copy-paste result, we find that we can
get the original size from Excel.Range.Width and Excel.Range.Height. For
paste method, we use
PowerPoint.Slide.Application.ActiveWindow.View.Pas teSpecial()
function(PowerPoint, similar for Word). , the return value is the
object(PasteElement) that pasted into Word/PowerPoint and its size could be
manipulated by PasteElement.Width and PasteElement.Height property.
Since we want the result has the 100% ratio of the original one, so we
assign original size to PasteElement.Width and PasteElement.Height, but we
have different behavior in 2003 and 2007 when we test this value from Office
GUI.

In 2007, the final size ratio is 99% which is slightly different from target
value, but In 2003, the final size ratio is 95% of the original one which is
not acceptable for us, so I have 2 questions:

1. Since the code is same for Office 2003 and 2007, why there is such
difference?

2. Is copy/paste a good way to transfer data between different office
application(Excel - PowerPoint / Word)?

Does anyone know about this? Thanks!

  #3   Report Post  
Old October 10th 09, 02:56 AM posted to microsoft.public.excel.programming
external usenet poster
 
First recorded activity by ExcelBanter: Jan 2010
Posts: 6
Default Object size by copy/paste is different between Office 2003 and

Thanks Barb.

But it seems the link you provided is not the same thing that I described.
The link mentions about the editing of the "embedded objects", but in my
case, the Excel result is copied into PowerPoint/Word as an STATIC image but
the size is not what I specified in code.

Does anyone know how to control the final size of the image pasted into
PowerPoint/Word?

"Barb Reinhardt" wrote:

I've had to change a registry setting so that Excel objects wouldn't resize
in PowerPoint.

http://support.microsoft.com/kb/300523

Might that be your problem?

"fmamstr" wrote:

Currently we are working on an add-in for Excel/PowerPoint/Word using Office
PIA(XP), the workflow is like this:

1) When the target application is Excel, we write our results directly into
Excel.Cell
2) When the target application is Word / PowerPoint, we first write the
results into Excel.Cell, then copy-paste the Excel.Range into Word/PowerPoint
as an static object via CLIPBOARD, but here we met a problem as described
below.

We want to control the "size" of the copy-paste result, we find that we can
get the original size from Excel.Range.Width and Excel.Range.Height. For
paste method, we use
PowerPoint.Slide.Application.ActiveWindow.View.Pas teSpecial()
function(PowerPoint, similar for Word). , the return value is the
object(PasteElement) that pasted into Word/PowerPoint and its size could be
manipulated by PasteElement.Width and PasteElement.Height property.
Since we want the result has the 100% ratio of the original one, so we
assign original size to PasteElement.Width and PasteElement.Height, but we
have different behavior in 2003 and 2007 when we test this value from Office
GUI.

In 2007, the final size ratio is 99% which is slightly different from target
value, but In 2003, the final size ratio is 95% of the original one which is
not acceptable for us, so I have 2 questions:

1. Since the code is same for Office 2003 and 2007, why there is such
difference?

2. Is copy/paste a good way to transfer data between different office
application(Excel - PowerPoint / Word)?

Does anyone know about this? Thanks!



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
Unable to copy and paste from BRIO to Microsoft Office Excel 2003. Margaret Hay Excel Discussion (Misc queries) 0 June 17th 09 03:06 PM
I have MS Office 2003 It wont highlight cells to copy & paste Sharen Excel Programming 0 January 28th 09 06:24 PM
Same Office 2003 but different VBA ToolsReference (object ref.) Edmund Excel Programming 5 August 17th 07 02:23 AM
Same Office 2003 but different VBA ToolsReference (object ref Edmund Excel Programming 1 August 17th 07 01:45 AM
Copy formulae and paste to range with Office 2003 Excel4Ever Excel Discussion (Misc queries) 0 November 21st 05 11:56 AM


All times are GMT +1. The time now is 04:28 PM.

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

About Us

"It's about Microsoft Excel"

 

Copyright © 2017