MS PowerPoint VBA Interview Questions and Answers with Examples

Home/100+ VBA Interview Questions and Answers with Examples/MS PowerPoint VBA Interview Questions and Answers with Examples

MS PowerPoint VBA Interview Questions and Answers with Examples

MS PowerPoint VBA Interview Questions and Answers explained with Example macros. Here are the list of most frequently asked basic MS PowerPoint VBA interview questions. All the questions are answered with simple examples. These questions will help you to answer basic questions to deal with MS PowerPoint VBA Programming/Development.

PREMIUM TEMPLATES LIMITED TIME OFFER

ON SALE80% OFF

50+ Project Management Templates Pack
Excel PowerPoint Word

Advanced Project Plan & Portfolio Template
Excel Template

Business Presentations Templates Pack
PowerPoint Slides

20+ Excel Project Management Pack
Excel Templates

20+ PowerPoint Project Management Pack
PowerPoint Templates

10+ MS Word Project Management Pack
Word Templates


Here is the following VBA procedure or macro to create new PowerPoint Presentation.

Sub Create_Presentation()
Presentations.Add
End Sub
Here is the following VBA procedure or macro to add slide in a presentation.

Sub Create_Presentation_WithSlide_Ex1()
With Presentations.Add
.Slides.Add Index:=1, Layout:=ppLayoutTitle
End With
End Sub
'Or
Sub Create_Presentation_WithSlide_Ex2()
With Presentations.Add
.Slides.Add 1, 1
End With
End Sub
Here is the following VBA procedure to create new PowerPoint Presentation and add slide.

'Create new PowerPoint Presentation and add slide
Sub Create_Presentation_WithSlide_Ex2()
With Presentations.Add
.Slides.Add 1, 1
End With
End Sub
Here is the following macro to save PowerPoint Presentation.

Sub Create_Save_Presentation()
'Variable Declaration
Dim NewPres As Presentation
'Create new Presentation
Set NewPres = Presentations.Add
'Your statements do something
'Save Presentation in a folder
NewPres.SaveAs FileName:="d:/TestPresentation.pptx"
End Sub
Here is the following macro to delete 1st slide in a PowerPoint Presentation.

Example 1:

Sub DeleteSlide_Presentation_Ex1()
ActivePresentation.Slides(1).Delete
End Sub

Example 2:

'Delete 3rd slide in a presentation
Sub DeleteSlide_Presentation_Ex2()
ActivePresentation.Slides(3).Delete
End Sub
Here is the following code to duplicate 1st slide in a presentation.
Example 1:

'Duplicate 1st slide in a presentation
Sub DuplicateSlide_Presentation_Ex1()
ActivePresentation.Slides(1).Duplicate
End Sub

Example 2:

'Duplicate 3rd slide in a presentation
Sub DuplicateSlide_Presentation_Ex2()
ActivePresentation.Slides(3).Duplicate
End Sub
Here is the following code to move slide from position one to three in a presentation.

Example 1:

'Move slide from position one to three in a presentation
Sub Move_Slide_Ex1()
ActivePresentation.Slides(1).MoveTo topos:=3
End Sub

Example 2:

'Move slide from position four to two in a presentation
Sub Move_Slide_Ex2()
ActivePresentation.Slides(4).MoveTo topos:=2
End Sub
Here is the following code to copy slide and Paste it in another location in a presentation.

'Copy third slide and Paste it as a first slide in a presentation
Sub CopyPaste_Slide()
ActivePresentation.Slides(3).Copy
ActivePresentation.Slides.Paste Index:=1
End Sub
Here is the following code to access a slide by its name in a presentation.

'Access a slide by its name
Sub Access_Slide_ByName()
ActivePresentation.Slides(2).Name = "Title"
ActivePresentation.Slides("Title").Select
End Sub
Here is the following code to access a slide by its index number in a presentation.

'Access a slide by its index number
Sub Access_Slide_ByIndex()
ActivePresentation.Slides(4).Select
End Sub
Here is the following procedure to start a slide show.

'Start a slide show
Sub Satrt_SlideShow()
ActivePresentation.SlideShowSettings.Run
End Sub
Here is the following procedure to exit a slide show.

'Exit a slide show
Sub Exit_SlideShow()
ActivePresentation.SlideShowWindow.View.Exit
End Sub
Here is the following procedure to display previous side in a presentation.

'Display previous side
Sub Display_PreviousSlide()
ActivePresentation.SlideShowWindow.View.Previous
End Sub
Here is the following procedure to display next side in a presentation.

'Display next side
Sub Display_NextSlide()
ActivePresentation.SlideShowWindow.View.Next
End Sub
Here is the following procedure to display first side in a presentation.

'Display first side
Sub Display_FirstSlide()
ActivePresentation.SlideShowWindow.View.First
End Sub
Here is the following procedure to display last side in a presentation.

'Display last side
Sub Display_lastSlide()
ActivePresentation.SlideShowWindow.View.Last
End Sub

Here is the link for more VBA Interview Questions and Answers. These are explained for examples.
100+ VBA Interview Questions

LIMITED TIME OFFER

Related pages


combobox propertiesvba programming basicswhat is ado connectionvba delete columnvba excel modexcel tutorial pivot tablesstatus update template powerpointvba redim arraylist box controlsub vbavba codesremove unique values in excelsum if vbaexcel remove macrosexcel macro arrayestimation format excelexcel consolidate multiple worksheetshow to find duplicate numbers in excel 2007simple vlookup formulavba password codesales dashboard templatesvba databaseadvanced excel macros examplesmacro enabled excel filevba basicsdo while loop in excel vbacreate new workbook vbaaccess 2013 activex controlsduplicate cell excelprotect sheet macromsgbox inputusing functions in vbabasics of vbaexcel reporting templates dashboardinsert macro excelhow to do a vlookup in excel 2013vlookup sampleexcel 2013 create macroexcel exercises for beginnersinsert tick box in excel 2007vlookup offsethow to hide unused cells in excel 2010excel hide columnsaptitude test questions and answers for freshers pdfselect last row vbawith selection vbacreating an excel macrovba closeexcel vba range addresssumif formula excelvb6 with access database exampledml commands in sql with examples pdfaccess vba in excelmacros in vbamerge cells excel 2013shortcut key for deleting sheet in excelexcel vba comboboxms sql interview questions and answers pdfdelete duplicates excelexcel vba scrollexcel 2010 unhide all columnsexcel iserror vlookupunhide all worksheetshow to remove blanks in excelhow to unhide columns on exceltrim function vbasum vlookup excelchange column width in excelgantt project planner excelhide and unhide columns in excelvba file system object