I am trying to print a word document, but with the code I have the document gets shut down before it gets a chance to print. I can put a breakpoint in the code and step through it and it will print before I get to the line to .Quit. Any ideas?
Code:
    objWdApp.Visible = True
    objWdApp.PrintOut
    If objWdApp.Options.PrintBackground = True Then
        DoEvents                                                
    End If
    objWdApp.Quit wdDoNotSaveChanges
    Application.DisplayAlerts = wdAlertsNone
    'frmdistricts.Show
    Screen.MousePointer = vbHourglass
    Set objwdRange = Nothing
    Set objWdDoc = Nothing
    Set objWdApp = Nothing
    Screen.MousePointer = vbDefault
    End If