June 10, 2009 at 7:24 pm
I have a .NET application that automatically sends an SSRS report to the printer. ie: no file created and not opened up. The landscape reports work fine , but recently all the portrait reports will not display the correct font size when printed. The font sizes appear to be double what they were in the past. Now, if I open these reports manually in Report Manager and select PDF or TIFF, they both print out fine. But having a .NET app with 1 button saves about 30 clicks, so they must be sent to the printer directly. Anyways, would this be related to interactive size or some other setting? The issue happens on both the web server and when I run the code from my local PC as the web server as well, so it appears to be either a report issue or a SSRS server issue that has recently changed automatically or perhaps a Mircosoft update as this occurred immediately after we rebooted the SSRS Server.
June 22, 2009 at 8:31 am
We are experiencing the same thing. Has anyone found a solution to this problem? Our customers expect our reports to be consistent, but it's impossible to control at this moment.
Please Help!
June 25, 2009 at 9:00 am
Hope this helps, it worked for me:
Instead of using Point destPoint = new Point(0, 0); for portrait, use the same code
that is needed for landscape, which is an array of points I assume Point[] points = new Point[3];(the code after my else statement.)
private void ReportDrawPage(Graphics g)
{
if (System.Web.HttpContext.Current.Session["rptPrintOrientation"].ToString() == "Landscape")
{
if (null == m_currentPageStream || 0 == m_currentPageStream.Length || null == m_metafile)
return;
lock (this)
{
// Set the metafile delegate.
int width = m_metafile.Width;
int height = m_metafile.Height;
m_delegate = new Graphics.EnumerateMetafileProc(MetafileCallback);
// Draw in the rectangle
// Point destPoint = new Point(0, 0);
// g.EnumerateMetafile(m_metafile, destPoint , m_delegate);
Point[] points = new Point[3];
Point destPoint = new Point(0, 0);
Point destPoint1 = new Point(width, 0);
Point destPoint2 = new Point(0, height);
points[0] = destPoint;
points[1] = destPoint1;
points[2] = destPoint2;
g.EnumerateMetafile(m_metafile, points, m_delegate);
// Clean up
m_delegate = null;
}
}
else
{
if (null == m_currentPageStream || 0 == m_currentPageStream.Length || null == m_metafile)
return;
lock (this)
{
// Set the metafile delegate.
int width = m_metafile.Width;
int height = m_metafile.Height;
m_delegate = new Graphics.EnumerateMetafileProc(MetafileCallback);
// Draw in the rectangle
//----if I used this code below like what is posted on the Internet, it only works on the physical box
//but not on the virtual machine for an unknown reason
//Point destPoint = new Point(0, 0);
//g.EnumerateMetafile(m_metafile, destPoint, m_delegate);
Point[] points = new Point[3];
Point destPoint = new Point(0, 0);
Point destPoint1 = new Point(width, 0);
Point destPoint2 = new Point(0, height);
points[0] = destPoint;
points[1] = destPoint1;
points[2] = destPoint2;
g.EnumerateMetafile(m_metafile, points, m_delegate);
// Clean up
m_delegate = null;
}
}
}
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply