Archive

Archive for April, 2010

SQL Server Reporting Services and rsAccessDenied

April 28th, 2010

Since this saved me what would have undoubtedly become a migraine, I thought I would repost it here. All credit goes to the original Author (see the jump):

SQL Server Reporting Services and rsAccessDenied

rsAccessDenied was all that stood between me and high fives from the customer.  The message from SQL Server Reporting Service (SRS) even displayed the clients log on name – so SRS KNEW who it was denying.  No impersonation was going to solve this one.

The Redirect string was fine, because it worked in test and on the server for those of us with admin rights.  (Yeah, I know — but this a practical blog — remember?)  So I fired up Report Manager to see what it had to say about the security settings on my report folders.  All I saw was the built in administrator and no way to add any more.

Hmmm.  At the Home folder level, I could add roles.  Since my client had access to the box, she must be in some local group or another, so I added Guests and Users with SRS Browser capacity.  I sauntered over to the client and acted as if I expected the report to work now.  It did.  I took my bows and made my exit with no small relief.

If this stuff was easy, nobody would need developers.

Uncategorized

Working with SSRS 2005

April 27th, 2010

Recently asked to replace Crystal Reporting Services with SQL Server Reporting Services I went about reading, testing, reading, and testing yet again the features of SSRS.

I found the Report Designer (SQL Server Business Intelligence Development Studio) to be a bit clunky… but, it does work once you get the hang of it. My main complaint is that its so tedious to reference values =Fields!foobar.Value … not sure why these aren’t aliased as with Crystal Reports. And the WYSIWYG leaves me scratching my head a bit b/c it just doesn’t work as fluidly as one would expect it to.

Dipping a bit more into the programming I found I could use the Microsoft Report Viewer to display the report by specifying a URL (in contrast to using the web services which I did not need). Unfortunately it took me a full two hours to determine how to set parameter values! …. While I may have moments of lunacy, last I checked I was not an idiot, so why was this not made more clear by the documentation since it seems like such a common need?

For those of you facing the same issue, here is how you do it:

//dynamically set parameter values

ReportParameter reportParams = new ReportParameter(“paramName”, “yourValue”);

reportViewer1.ServerReport.SetParameters(new ReportParameter[] {reportParams});

*Note that the parameters are case sensitive.

Uncategorized

Generating Excel Reports in Binary Format

April 26th, 2010

Some years ago I wrote a .NET Class that used the Microsoft Office Interop Services (Microsoft.Office.Interop.Excel). While I wrote it nearly complete to the exact specification I found it was never quite fast enough since a) it was using COM and b) I had to deal with the .NET wrappers for that unmanaged code. Knowing I had to produce the report in binary for optimal performance I pretty much gave up on ever discovering the format of the file… until today, while researching SQL Server Reporting Services when I came across these links:

“OpenOffice.org’s documentation of the Microsoft Excel File Format”

“Microsoft Office Excel 97 – 2007 Binary File Format Specification (*.xls 97-2007 format)”

Happy coding.

Uncategorized

Best Free Image Converter (png to gif)

April 12th, 2010

If you do any web programming you will eventually need to do some image conversions. This is especially true if you download icon libraries that are in PNG and need to convert them to transparent GIFs.

My favorite and free program for this is ImageMagick. You will find the command line tool especially useful for doing batch conversions.

http://www.imagemagick.org/script/index.php

Note: If you can use PNG stick with it as you will lose opacity layers if you convert these to GIF. Unfortunately some older browsers don’t support PNG so I typically use GIF for compatibility reasons.

Uncategorized

Direct2d (hardware acceleration) FireFox

April 8th, 2010

This is amazingly fast… check it out. IE 9 is supposed to have hardware acceleration too…. (btw: this won’t work on XP)

http://www.basschouten.com/blog1.php/2010/03/02/presenting-direct2d-hardware-acceleratio

Uncategorized