While I realize that I could just show the form off-screen and hide it, along with many other forms of WinForms hackish wizardry, I'd rather stick with the zen path and get this done right. I have a SSRS local report (so no server) that I want to give the user the option of either viewing or printing (in other words, I don't want to force them to view to print). Unfortunately, the ReportViewer control complains about its "state" when I try to print it either as a component I'm creating explicitly in my code (inside a using() block, of course) or if I try to instantiate my viewer form and just print without ever showing it.
Is there a means to do this that will sit well with me, or should I just show it off-screen and move on with my life?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…