Have you ever wanted to collect information or get feedback from people who view your PowerPoint presentation on their own? You might have a self-running presentation at a convention or in the lobby of your organization. You could ask them if they liked the presentation and get comments, or you could even collect names and e-mail addresses of people who want more information.
While accomplishing this requires some programming, I recently discovered an article that made it easy enough for a non-programmer like me to get the job done.
The Microsoft Office PowerPoint site has a series of articles on ActiveX controls. Here’s their definition of ActiveX controls:
“ActiveX controls include scroll bars, command buttons, option buttons, toggle buttons, and other controls that you use to create custom programs, dialog boxes, and forms.”
One of the articles is called, “Become a feedback guru using ActiveX controls.” (Update: Unfortunately, this article is no longer available) This article runs you through the steps to create a slide like this:
Tip: The article doesn’t explain how to change the size of the font. In the Properties box, which the article describes, click the Font item, then click the Ellipsis button that appears. Then you can specify a font, font style, and font size. Another technique that the article doesn’t explain is that you can resize each control, just like you resize any object on a slide.
Viewers can then fill out the survey in slide show view, as you see here:
Nice, isn’t it?
The result is a text file, named Survey_results.txt, that is created in the same folder as the presentation. Here’s a sample:
What was unique about this article, in my view, was its clarity and the simplicity of the code. Because it was so simple, I was able to modify it to create a different type of slide, one that collects names and e-mail addresses.
(I have a similar technique in my book, How to Do Everything with Microsoft Office PowerPoint 2003 and 2007, which saves data to an Excel spreadsheet. However the code for that technique is more complex.)
Using the technique in this article, h ere’s what my slide looks like:
Note that my slide doesn’t use any new controls. It uses labels, text boxes, and a button like the original slide, but doesn’t use any option buttons. So I didn’t have to figure out anything new.
Here’s the resulting file (with made-up e-mail addresses:
In order to understand how I did this, you need to read the article that I referenced above. Once you’ve gone through it, look at the code below, which is a modification of the code in the article:
Private Sub CommandButton1_Click()
‘Purpose: Creates a text file and stores the survey results
‘in the text file.
‘You must set a refernce to the Microsoft Scripting Runtime
‘(Tools menu, References command, check the Microsoft Scripting
‘Runtime box, and then click OK).
Dim objFSO As Scripting.FileSystemObject
Dim objTS As Scripting.TextStream
‘Create the text file
Set objFSO = New Scripting.FileSystemObject
Set objTS = objFSO.OpenTextFile(CurDir & “/Survey_results.txt”, ForAppending, True)
‘ Write the results to the text file and then
‘close the file.
objTS.WriteLine “Name = ” & Me.TextBox1.Text
objTS.WriteLine “E-mail address = ” & Me.TextBox2.Text
objTS.WriteLine “E-mail address (verify) = ” & Me.TextBox3.Text
‘Thank the user.
MsgBox “Thank you. We’ll send you more information shortly.”
‘Clear the results for next time.
Me.TextBox1.Text = “”
Me.TextBox2.Text = “”
Me.TextBox3.Text = “”
‘Return to beginning of presentation for next viewer.
The next-to-last line is something I added to move the presentation back to the first slide so the next viewer can start at the beginning, but you don’t need to add this line.