Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27
Default Macro for PPT changes the object number when looping over 42 times.

Hi,

I have an issue with a macro which creates automatic slides for me in
PPT. The data is taken from excel and then put in the corresponding
place (object) in PPT. However, after having looped exactly 42 times,
the object which is being pasted to (I have one file which is the
source file that is opened and manipulated with the data over and
over
again and saved everytime depending on the analysed firms name)
changes number from 292 to 293, and if I click it again it changes to
294 etc... So for the first 42 times the object continues to be
"group
292" but on the 43 rd time, it becomes "group 293", any suggestions
as
to why this is and how to solve it? I am thinking maybe I need to
create a templatefile instead of a normal PPT presentation file used
as template?


The code used is:

Rectangle = "Group 292"

oPPTApp.ActiveWindow.Selection.SlideRange.Shapes(R ectangle).Select


Best regards,


Peder

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default Macro for PPT changes the object number when looping over 42 times.

I would give the objects in PPT real names, not the default names. In PPT
2003 and earlier (not sure about PPT 2007), the UI doesn't give you a method
to name an object. See
http://www.cpearson.com/PowerPoint/S...apeRenamer.htm for a PPT COM
Add-In that allows you to name slides and objects on slides.


--
Cordially,
Chip Pearson
Microsoft Most Valuable Professional
Excel Product Group, 1998 - 2008
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)



"Wesslan" wrote in message
...
Hi,

I have an issue with a macro which creates automatic slides for me in
PPT. The data is taken from excel and then put in the corresponding
place (object) in PPT. However, after having looped exactly 42 times,
the object which is being pasted to (I have one file which is the
source file that is opened and manipulated with the data over and
over
again and saved everytime depending on the analysed firms name)
changes number from 292 to 293, and if I click it again it changes to
294 etc... So for the first 42 times the object continues to be
"group
292" but on the 43 rd time, it becomes "group 293", any suggestions
as
to why this is and how to solve it? I am thinking maybe I need to
create a templatefile instead of a normal PPT presentation file used
as template?


The code used is:

Rectangle = "Group 292"

oPPTApp.ActiveWindow.Selection.SlideRange.Shapes(R ectangle).Select


Best regards,


Peder


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27
Default Macro for PPT changes the object number when looping over 42times.

Chip,

Thanks ever so much. You have made my day!

Sincerly

Peder

On Feb 18, 9:48*am, "Chip Pearson" wrote:
I would give the objects in PPT real names, not the default names. In PPT
2003 and earlier (not sure about PPT 2007), the UI doesn't give you a method
to name an object. Seehttp://www.cpearson.com/PowerPoint/SlideAndShapeRenamer.htmfor a PPT COM
Add-In that allows you to name slides and objects on slides.

--
Cordially,
Chip Pearson
Microsoft Most Valuable Professional
* * Excel Product Group, 1998 - 2008
Pearson Software Consulting, LLCwww.cpearson.com
(email on web site)

"Wesslan" wrote in message

...



Hi,


I have an issue with a macro which creates automatic slides for me in
PPT. The data is taken from excel and then put in the corresponding
place (object) in PPT. However, after having looped exactly 42 times,
the object which is being pasted to (I have one file which is the
source file that is opened and manipulated with the data over and
over
again and saved everytime depending on the analysed firms name)
changes number from 292 to 293, and if I click it again it changes to
294 etc... So for the first 42 times the object continues to be
"group
292" but on the 43 rd time, it becomes "group 293", any suggestions
as
to why this is and how to solve it? I am thinking maybe I need to
create a templatefile instead of a normal PPT presentation file used
as template?


The code used is:


Rectangle = "Group 292"


oPPTApp.ActiveWindow.Selection.SlideRange.Shapes(R ectangle).Select


Best regards,


Peder- Hide quoted text -


- Show quoted text -


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27
Default Macro for PPT changes the object number when looping over 42times.

Chip,

I had a problem with installing the COM Add-In. I managed to find it
in the Com Add-In as you describe in the helpfile under the "add"
section and browsed for it. Both the helpfile and the .dll file are in
the same catalog, but once I have pressed "Add" it doesn't show up
under the "Add-Ins available". I am using the 2003 office, is this
something you have had others experience before?

If you have some help or the original code, I would truly appreciate
it.

Sincerly,

Peder
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
Looping a macro x times(x being activecell.value)? [email protected] Excel Programming 4 July 7th 06 08:08 AM
How to run a Macro specified number of times? brutonparish[_3_] Excel Programming 1 July 4th 06 04:46 AM
Looping Macro with input boxes all related to one number Jeremy Excel Programming 0 October 26th 05 04:40 AM
Looping Macro for fixed number of rows Robert Excel Programming 5 February 28th 05 04:41 PM
Run Macro from another X number of times BOHICA Excel Programming 3 November 26th 03 07:13 PM


All times are GMT +1. The time now is 08:30 PM.

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

About Us

"It's about Microsoft Excel"