Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 12-03-2012, 06:25 AM
CarpetRemnant CarpetRemnant is offline How to import a list of names into PowerPoint from Excel? Windows 7 32bit How to import a list of names into PowerPoint from Excel? Office 2007
Novice
How to import a list of names into PowerPoint from Excel?
 
Join Date: Dec 2012
Posts: 1
CarpetRemnant is on a distinguished road
Default How to import a list of names into PowerPoint from Excel?

Hello,

I would like to import a list of names (about 50) from an Excel document into PowerPoint in such a way that each name is on a seperate slide.
Ideally I would also like to import a picture with each name as well.

Does anyone know how to do this?/Whether this can be done?

Thanks,

George
Reply With Quote
  #2  
Old 12-04-2012, 12:24 AM
macropod's Avatar
macropod macropod is offline How to import a list of names into PowerPoint from Excel? Windows 7 64bit How to import a list of names into PowerPoint from Excel? Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,938
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Hi george,

Try something based on the following Excel macro:
Code:
Sub Excel2PwrPt()
' Requires a reference to Microsoft PowerPoint Object Library
Application.ScreenUpdating = False
Dim StrPath As String, LRow As Long, i As Long, x As Long
StrPath = "C:\Users\George\Documents\"
Dim PwrPt As PowerPoint.Application
Dim pptPres As PowerPoint.Presentation
Dim pptSld As PowerPoint.Slide
Dim pptLayout As PowerPoint.CustomLayout
' Create an instance of PowerPoint
Set PwrPt = New PowerPoint.Application
PwrPt.Visible = True
' Open the presentation
Set pptPres = PwrPt.Presentations.Open(Filename:=StrPath & "Presentation1.ppt")
x = pptPres.Slides.Count
' Reference active slide
Set pptSld = pptPres.Slides(x)
With Worksheets("Sheet1")
  LRow = .Range("A65536").End(xlUp).Row
  For i = 1 To LRow
    pptPres.Slides.Add Index:=x + i, Layout:=ppLayoutTitleOnly
    ' Insert the Excel Cell's value from Column A into the slide title
    pptPres.Slides(x + i).Shapes(1).TextFrame.TextRange.Text = .Cells(i, 1).Value
    ' Insert the picture referenced in Column B
    pptPres.Slides(x + i).Shapes.AddPicture Filename:=StrPath & .Cells(i, 2).Value, _
     LinkToFile:=False, Top:=100, Left:=150, Width:=400, SaveWithDocument:=True
  Next i
End With
' Clean up
Set pptSld = Nothing: Set pptPres = Nothing: Set PwrPt = Nothing
Application.ScreenUpdating = True
End Sub
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #3  
Old 12-04-2012, 11:42 AM
Jamal NUMAN Jamal NUMAN is offline How to import a list of names into PowerPoint from Excel? Windows 7 64bit How to import a list of names into PowerPoint from Excel? Office 2010 64bit
Expert
 
Join Date: Nov 2010
Posts: 513
Jamal NUMAN is on a distinguished road
Question

Thank you Paul for sharing the code.

Could you please elaborate more how can the code be used? In the attached screenshot, for example, I need to included two fields from the excel file into the powerpoint. How such thing can be accomplished using the code?


Best

Jamal
Attached Images
File Type: jpg Clip_524.jpg (109.0 KB, 12 views)

Last edited by macropod; 12-04-2012 at 02:11 PM. Reason: Deleted unnecessary quote of entire previous post.
Reply With Quote
  #4  
Old 12-04-2012, 02:17 PM
macropod's Avatar
macropod macropod is offline How to import a list of names into PowerPoint from Excel? Windows 7 64bit How to import a list of names into PowerPoint from Excel? Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,938
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Hi Jamal,

As written, the code simply inserts text content from column A in the Excel workbook into the first textbox on the new slides it creates (it also inserts a picture onto the page - as per the OP's requirements). You don't need your <Name> or <Course> tags for that. Obviously, if your needs are different, the code would need to be modified to suit - it's not a one-size-fits-all solution.

PS: Please don't automatically quote the entire previous post in your replies. If there is a particular element in the previous post that you need to reference, quote just that part.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #5  
Old 12-07-2012, 11:08 AM
Jamal NUMAN Jamal NUMAN is offline How to import a list of names into PowerPoint from Excel? Windows 7 64bit How to import a list of names into PowerPoint from Excel? Office 2010 64bit
Expert
 
Join Date: Nov 2010
Posts: 513
Jamal NUMAN is on a distinguished road
Default

Thank you very much Paul. It is clear now.

Best

Jamal
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Import field from Excel to Powerpoint xgravity23 Office 8 11-22-2012 02:08 PM
How to import a list of names into PowerPoint from Excel? auto insert names from list for printing andreipopa2k Word 1 12-09-2011 01:51 PM
Import formatted text from Word into PowerPoint parboy PowerPoint 0 07-06-2011 08:52 AM
How to import a list of names into PowerPoint from Excel? Using a list of names in credits effect Pemberton PowerPoint 4 08-17-2010 02:10 AM
How to import a list of names into PowerPoint from Excel? Random names from a given list professor snape Excel 1 06-06-2009 09:39 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 08:12 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2023 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft