views:

11

answers:

1

I'm using the Crystal Reports Basic for Visual Studio 2008 to print reports. I have just one user that gets periodic errors saying "The handle is invalid". If she tries printing a second time, it works just fine. I've looked over her machine and it looks like it has all the same software as everyone else, and of course it never happens when I'm around.

The code I'm using is: frmPrint.LogTag1.PrintToPrinter(1, True, 1, 0)
I'm not sure if there is any other information that I can get from an end user machine to help me figure out where the problem is. ErrorToString() only returns that one line.

A: 

It is a low-level Windows error. Could be a bug in Crystal Reports, could be a bug in the printer driver, could be environmental with some kind of misbehaving system add-on. You'll never find out which it is if you don't have the source code for these large chunks of code so you can debug it. You don't and you can get it.

It is not a bug in your code, ask the IT staff to get that user another machine. If that doesn't help then you'll have to bounce this to Crystal Decisions (or whatever they are called these days). This is otherwise a standard IT matter.

Hans Passant
Hmm, this stinks.OK, so the only solution is to get her another machine.Or reformat and start over from scratch?It would be nice if I could use a try catch EX as exception and get some more info, so I can try to get Crystal Decisions to help with it. Any advice on what kind of stuff I can get get from EX besides EX.message?
AndyD273