• OK Krusna, thanks for the detailed reply, it was very helpful.

    Currently, my suspicion is that either the "PDF Printer" settings as user specific and have not been set for whatever user your SQL Server uses for sp_ExecuteSql, or else the default printer has not been set for that user.

    I think that you will need to check with the makers of your PDF Printer to see have you can set these from the command line or else how to configure them for another use in advance.

    [font="Times New Roman"]-- RBarryYoung[/font], [font="Times New Roman"] (302)375-0451[/font] blog: MovingSQL.com, Twitter: @RBarryYoung[font="Arial Black"]
    Proactive Performance Solutions, Inc.
    [/font]
    [font="Verdana"] "Performance is our middle name."[/font]