I have some C# code that will upload images and files into a db. Currently I thought It working for all documents that fit a list of mimetypes. However It fails on some pdf's.
I have narrowed the problem down to the fact that some pdf's are in the 1.3 format and some are in the 1.4 format. The 1.4 works and is properly uploaded, however 1.3 does not upload and it does not generate any runtime errors it just fails to be added.
Some of the current code for uploading the pdf is
Checks for valid MIME Type
...
byte[] fileData = new byte[uploadFile.ContentLength];
uploadFile.InputStream.Read(fileData, 0, uploadFile.ContentLength);
...
Continues on to Uploads to db.
For pdf's it is looking for "application/pdf" as the mime type. I don't think there is another type for pdfs in the 1.3 format, but maybe I am wrong.
Anyone else ever have this problem before and any advice on how to correct it?