×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

How can I add text in a ppt?

How can I add text in a ppt?

How can I add text in a ppt?

(OP)

I found how add Picture inside a ppt in below thread:
http://www.eng-tips.com/viewthread.cfm?qid=330252

But I would need also to add a text from a catscript. How can I do this? I tried like below but it does not work:

CODE -->

ppt.ActiveWindow.Selection.SlideRange.Shapes.AddTextbox(msoTextOrientationHorizontal, 100, 100, 200, 50).TextFrame.TextRange.Text = "Test Box" 


Thank you.

RE: How can I add text in a ppt?

(OP)
You are right, I could do it like you told but it is not exactly what I need. Off course, if no other way than I will proceed as you told.
I would need more control on the ppt in order to make it automatically using the company standard to be sent to our customer.
I want to make it a little bit more complex, with more functionality, but I was stuck just from the beginning with adding a simple text :)
Should be possible to add a text in a ppt using a catscript?

RE: How can I add text in a ppt?

Is this what you want?




if it is:

CODE --> vb.net

PPT = PPT.ActivePresentation
            Dim SlidesCount = PPT.Slides.Count
            Dim oSlide = PPT.Slides.Add(SlidesCount + 1, Powerpoint.PpSlideLayout.ppLayoutTitleOnly)
            With oSlide.Shapes.Item(1).TextFrame.TextRange
                .Text = TextBox1.Text' this is the string that adds the text
                .Font.Name = "Eurostile LT (Headings)"
                .Font.Size = 48
            End With 

Tiago Figueiredo
Tooling Engineer

RE: How can I add text in a ppt?

(OP)
Thank you TiagoFigueiredo, this was exactly what I was looking for :) .

I updated the intial code with below code inside a catscript:

CODE -->

uNewS.Layout = 4 '12 means no text / 4 means title only 


CODE -->

With uNewS.Shapes.Item(1).TextFrame.TextRange
            .Text = AnnViewName 'this is the string that adds the text
            .Font.Name = "Eurostile LT (Headings)"
            .Font.Size = 48
        End With 

RE: How can I add text in a ppt?

Now I need your help. One of my collegues is trying to do this for NX. wich is very simillar to CATscript.
How do you call PowerPoint?

Tiago Figueiredo
Tooling Engineer

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources