title: Simple vba command to delete a section of PowerPoint slides
body: <p>I have a large master presentation and I want a VBA UserForm to offer checkboxes for inclusion/deletion of slide sections for custom presentations. </p>
  
  <p>My form is working well, but I'm not getting the syntax right to delete a section of slides based on a checkbox being unchecked upon form button click. I found very limited reference material from Microsoft.</p>
  
  <pre><code>If chkAutomotive = False Then
          ActivePresentation.SectionProperties.Delete(1,True)
      End If
  </code></pre>
  
  <p>In this case, the Automotive section of slides is the first section and if the checkbox is unchecked, I'd like to delete the slides in that section.</p>