Automating Survey Distribution
My solution uses Outlook Tasks to manage the survey schedule and keep track of when surveys were sent. In Outlook's Tasks folder, select New Task, and label the subject Send Surveys. Click Recurrence, and set the task to run daily. You also need to turn on the reminder and set an appropriate reminder time for your schedule.
Return to the Visual Basic Editor, and in the ThisOutlookSession module, enter the VBA code that Listing 2 shows. This code contains two subroutines: Application_Reminder and SendSurvey. The Application_Reminder subroutine starts when your reminder opens. If the reminder matches your task by the Subject line, the subroutine will prompt you to send the surveys. If you click Yes, the subroutine connects to a database to collect the email address and ticket numbers for the surveys, then sends the surveys. The subroutine marks the task as complete and creates a new task for the next day. If you click No, you'll see a reminder dialog box to either dismiss or snooze the item until a later time. If you snooze the item, the subroutine will prompt you again at the chosen time. If you dismiss the reminder, the subroutine will ignore the task and won't send any surveys that day. In addition, you'll have to reopen the task to reset the reminder or manually mark it as complete. . . .
medfac January 26, 2007 (Article Rating: