Prepare throws Format Exception; Base64 string not valid even though it is

I have a very strange problem, I am using the open source version of fast reports to create .pdf files and save them in a database but for some reason I get a FormatException on the Prepare function call that says: "The input is not a valid Base-64 string as it contains a non-base 64 character, more than two padding characters, or an illegal character among the padding characters.". The base64 string that gets used however is in fact valid. The only thing I suspect could be the problem is the xml file that gets loaded beforehand, however on a different computer with the same code and dependencies this error does not occur so I dont know what else to do.

I have provided the xml file (unformatted) and the base64 string I used.

Base64String:

iVBORw0KGgoAAAANSUhEUgAAAVYAAADGCAYAAACJvqh0AAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAARcSURBVHic7d0xaGRVFAbgPyxEUgzINGlMl8ZFmy0HG7ecNo2YNm3aYGmb0mC3lgGrLYM2AZstIyxEEFLFwrUIuIEly0rYWHgHRGbm3WEe3Bn5Ppguxal+Tt6995wEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAIAaj1oXAKw1GQLQk90kp0leld9B64IA1tVOkmdJHv7zu0uy3bo4gHWyk+RkSqBOfvdJ9lsXCbAOtjsC9d+/cetiAVbZJFDvKgL1JslR64IBVtUwyXGS28pA/TrJoHXRAKtokH9CcpFAHbYuGmAVDcq/8TcVgXobgQow05ZABejHZpLDcqm/JlCPBSrAdJNAvRaoAMvZLM9NBSrAkh6Vl1BXCwSqJ6kAU2wsEKh3AhVgvr0klwIVYHmLBOqJQAWY7SDJS4EKsLz9JK8rJ06dlJF/AEwxTnIhUAGWJ1ABejJO8qIyUL8VqACzLRKoL5M8aV0wwKp6Whmo92VD6setCwZYVbWB+pDkeVk9DcAUowUD9XHrggFW1SjJeWWgnvmGCjDbIoF6Xv4egCkWCdQXAhVgts+S/FIZqBflmhUAM3xXGaiXZToVADPsVQ6ZngTqRuuCAVbVqPI9/1WZTiVQAWbYLXdMuwL1rsxPfdS6YIBVNSyTpGqen35ftqUCMMVmkqMkNxWB+izJR60LBlhltdtPzzw/BZiv9mDqsgxUAWCG2oOp69LNAjDD5GDqXUeg3pbvrVutCwZYVZODqdvKgynrpAHmcDAF0JNFDqZMnQKYw8EUQE8mB1P3DqYAlvNBkq8WOJgati4YYJV9U3F16sHCPoBuO0l+9mIKoB+HFf/2O5gCqLBT7prOC9S3DqYA6uxXdKm/ejEF0G27okv9s0zwB6DDfsXQ6ee6VIBuw4qXU6+slgaos1dCU5cKsKRhklNdKkA/xpVdqqeoAB0G5e2+LhWgB0/L6yhdKsCStnSpAP0ZVXSpp7pUgG5bZQC1LhWgB6OKRX66VIAKHyb5Icl7XSrA8r5I8pcuFaAfh7pUgH5sVFyjci8VoNIwyfmcQH2nSwWo96TjburrJJ+2LhJgXex3rJ7+0e4pgHrHHd9Tj1sXCLAuBh07qO6snQaot9vxiuq6fHMFoMK4Y/30uatUAPWOOr6nnpR7rAB02OzYQ/U+yUHrIgHWxU6SizmhelO2AABQYdSx3O+iBC8AFQ6S3HdMpXLpH6DCRsWU/6PWRQKsi2GSnzou/Y9bFwmwLj5P8nZOqF4ledy6SIB18secUD0rT1gBqDQwRAWgf79NufRviArAEj5J8nsJ1TdJvmxdEMD/xWbrAgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACgob8BCnEaJOFfNZcAAAAASUVORK5CYII=

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.