?
Solved

Set Label.Caption in a PowerPoint Presentation

Posted on 2003-03-08
5
Medium Priority
?
2,193 Views
Last Modified: 2008-02-26
Hi and a good evening.
My Question :
How can I set a Label.Caption in a Powerpoint Presentation with a Visual Basic Program?
I have tried this:
Dim Lab1 As Label
Set Lab1 = ActivePresentation.Slides(1).Shapes(2).OLEFormat.Object
With Lab1
.Caption= Text1.Text
End With
Yes sure I have open before the Presentation!

But it doesn't work.

Thanks for answer.
0
Comment
Question by:BraveNewWorld
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 5

Expert Comment

by:JohnMcCann
ID: 8095661
   With ActivePresentation.Slides(1).Shapes(1)
        .HasTextFrame = True
        .TextFrame.TextRange.Text = "Hello"
    End With
0
 

Author Comment

by:BraveNewWorld
ID: 8097563
Hi.
First thanks for your reply.
I mean an ActiveX Label from the Toolbox. Not a TextFrame.
The Presentation has no TextFrame. Only 4 Labels.This 4 Label Captions I want set over a Visual-Basic Program.
Thanks
0
 
LVL 5

Accepted Solution

by:
JohnMcCann earned 500 total points
ID: 8097696
Ok try

ActivePresentation.Slides(1).label1.Caption ="Changed the caption"
0
 

Expert Comment

by:CleanupPing
ID: 8900469
BraveNewWorld:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
Experts: Post your closing recommendations!  Who deserves points here?
0
 
LVL 49

Expert Comment

by:DanRollins
ID: 9074482
Moderator, my recommended disposition is:

    Accept JohnMcCann's comment(s) as an answer.

DanRollins -- EE database cleanup volunteer
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses

765 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question