Our system uses a lot of large Bitmaps (System.Drawing.Bitmap) and sometimes we run out of memory and gets a “Parameter is not valid” error. This makes sense, since it can be difficult to allocate large continuous chunk of memory.
So the question is… If we upgraded the system to 64bit, would this problem go away?
If this is a memory allocation problem (due to fragmentation of your large object heap it is quite conceivable that you would have trouble allocating 100MB chunks after 20 or so images have been loaded, even if some of them have subsequently been unloaded), then moving to 64 bit should help – the much larger address space should give the heap plenty of room to work, and thus alleviate the symptoms.
A memory issue should produce an OutOfMemoryException, but it’s possible that the bitmap handling code in .net is catching this and effectively converting into an InvalidParameterException. However, there is a possibility that there is another issue relating to the size/format of the images, and it is genuinely an Invalid Parameter.