62 instantiations of FileFormatException
PresentationCore (29)
MS\Internal\FontCache\FontCacheUtil.cs (1)
838throw new FileFormatException(new Uri(fileName));
MS\Internal\FontFace\CompositeFontParser.cs (2)
873throw new FileFormatException(new Uri(_reader.BaseURI, UriKind.RelativeOrAbsolute), x); 943throw new FileFormatException(new Uri(fileName, UriKind.RelativeOrAbsolute), message, innerException);
MS\Internal\FontFace\FontDriver.cs (3)
145throw new FileFormatException(SourceUri, e); 189throw new FileFormatException(SourceUri); 213throw new FileFormatException(SourceUri, e);
MS\Internal\Shaping\OpenTypeCommon.cs (1)
986throw new FileFormatException();
MS\Internal\Shaping\OpenTypeLayout.cs (6)
147if ((offset + 1) >= m_length) throw new FileFormatException(); 154if ((offset + 1) >= m_length) throw new FileFormatException(); 161if ((offset + 3) >= m_length) throw new FileFormatException(); 168if ((offset+1)>=m_length) throw new FileFormatException(); 1248throw new FileFormatException(); 1264throw new FileFormatException();
MS\Internal\Shaping\Substitution.cs (1)
233throw new FileFormatException();
MS\Internal\Text\TextInterface\DWriteUtil.cs (1)
28throw new System.IO.FileFormatException();
src\Microsoft.DotNet.Wpf\src\Common\Graphics\wgx_render.cs (11)
805return new System.IO.FileFormatException(null, SR.Image_UnknownFormat, exceptionForHR); 846return new System.IO.FileFormatException(null, SR.Image_DecoderError, exceptionForHR); 849return new System.IO.FileFormatException(null, SR.Image_HeaderError, exceptionForHR); 879return new System.IO.FileFormatException(null, SR.Image_UnexpectedMetadataType, exceptionForHR); 882return new System.IO.FileFormatException(null, SR.Image_RequestOnlyValidAtMetadataRoot, exceptionForHR); 888return new System.IO.FileFormatException(null, SR.Image_DuplicateMetadataPresent, exceptionForHR); 891return new System.IO.FileFormatException(null, SR.Image_PropertyUnexpectedType, exceptionForHR); 894return new System.IO.FileFormatException(null, SR.Image_TooMuchMetadata, exceptionForHR); 906return new System.IO.FileFormatException(null, SR.Image_InvalidColorContext, exceptionForHR); 937return new System.IO.FileFormatException(SR.Media_FileFormatNotSupported, exceptionForHR); 940return new System.IO.FileFormatException(SR.Media_PlaylistFormatNotSupported, exceptionForHR);
System\Windows\Media\GlyphTypeface.cs (1)
146throw new System.IO.FileFormatException(typefaceSource);
System\Windows\Media\Imaging\BitmapDecoder.cs (2)
94throw new FileFormatException(bitmapUri, SR.Image_CantDealWithUri); 138throw new FileFormatException(null, SR.Image_CantDealWithStream);
PresentationFramework (22)
System\Windows\Documents\FixedDocument.cs (3)
881throw new FileFormatException(SR.InvalidDSContentType); 910throw new FileFormatException(SR.InvalidSFContentType); 914throw new FileFormatException(SR.InvalidStoryFragmentsMarkup);
System\Windows\Documents\FixedSchema.cs (14)
46throw new FileFormatException(SR.XpsValidatingLoaderUnsupportedEncoding); 53throw new FileFormatException(SR.XpsValidatingLoaderUnsupportedEncoding); 215throw new FileFormatException(SR.XpsValidatingLoaderUnsupportedRootNamespaceUri); 325throw new FileFormatException(SR.XpsValidatingLoaderUnsupportedMimeType); 585throw new FileFormatException(SR.XpsValidatingLoaderMoreThanOnePrintTicketPart); 596throw new FileFormatException(SR.XpsValidatingLoaderPrintTicketHasIncorrectType); 607throw new FileFormatException(SR.XpsValidatingLoaderMoreThanOneThumbnailPart); 619throw new FileFormatException(SR.XpsValidatingLoaderThumbnailHasIncorrectType); 639throw new FileFormatException(SR.XpsValidatingLoaderRestrictedFontHasIncorrectType); 655throw new FileFormatException(SR.XpsValidatingLoaderMoreThanOneDiscardControlInPackage); 666throw new FileFormatException(SR.XpsValidatingLoaderDiscardControlHasIncorrectType); 678throw new FileFormatException(SR.XpsValidatingLoaderMoreThanOneThumbnailInPackage); 690throw new FileFormatException(SR.XpsValidatingLoaderThumbnailHasIncorrectType); 729throw new FileFormatException(SR.XpsValidatingLoaderUnsupportedMimeType);
System\Windows\Documents\XPSS0ValidatingLoader.cs (5)
82throw new FileFormatException(SR.XpsValidatingLoaderUriNotInSamePackage); 138throw new FileFormatException(SR.XpsValidatingLoaderUnsupportedMimeType); 180throw new FileFormatException(SR.XpsValidatingLoaderDuplicateReference); 208throw new FileFormatException(SR.XpsValidatingLoaderUnlistedResource); 213throw new FileFormatException(SR.XpsValidatingLoaderUnsupportedMimeType);
PresentationUI (2)
MS\Internal\Documents\RightsManagementManager.cs (1)
1404new FileFormatException());
MS\Internal\Documents\RightsManagementProvider.cs (1)
1279throw new FileFormatException(
System.IO.Packaging (9)
System\IO\Packaging\InternalRelationshipCollection.cs (1)
571throw new FileFormatException(SR.RelationshipPartIncorrectContentType);
System\IO\Packaging\Package.cs (1)
428throw new FileFormatException(SR.BadPackageFormat);
System\IO\Packaging\PackagingUtilities.cs (1)
53throw new FileFormatException(SR.EncodingNotSupported);
System\IO\Packaging\PartBasedPackageProperties.cs (4)
441throw new FileFormatException(SR.NoExternalTargetForMetadataRelationship); 449throw new FileFormatException(SR.DanglingMetadataRelationship); 454throw new FileFormatException(SR.WrongContentTypeForPropertyPart); 469throw new FileFormatException(SR.MoreThanOneMetadataRelationships);
System\IO\Packaging\ZipPackage.cs (2)
370throw new FileFormatException(SR.ZipZeroSizeFileIsNotValidArchive); 406throw new FileFormatException(SR.FileContainsCorruptedData);
19 references to FileFormatException
PresentationCore (11)
MS\Internal\Shaping\OpenTypeLayout.cs (7)
317catch (FileFormatException) 334catch (FileFormatException) 370catch (FileFormatException) 388catch (FileFormatException) 916catch (FileFormatException) 993catch (FileFormatException) 1122catch (FileFormatException)
MS\Internal\Shaping\OpenTypeLayoutCache.cs (1)
344catch (FileFormatException)
System\Windows\Media\FontFamily.cs (1)
521catch (FileFormatException)
System\Windows\Media\Imaging\BitmapImage.cs (1)
553catch (FileFormatException)
System\Windows\Media\Imaging\BitmapSource.cs (1)
1156catch (FileFormatException)
PresentationFramework (3)
MS\Internal\IO\Packaging\XpsFilter.cs (1)
426catch (FileFormatException ex)
System\Windows\ColorConvertedBitmapExtension.cs (1)
123catch (FileFormatException)
System\Windows\Documents\WpfPayload.cs (1)
342catch (System.IO.FileFormatException)
PresentationUI (1)
MS\Internal\Documents\Application\RightsManagementErrorHandler.cs (1)
259(exception is System.IO.FileFormatException))
System.IO.Packaging (1)
System\IO\Packaging\Package.cs (1)
383/// <exception cref="FileFormatException">The package has a bad format.</exception>
WindowsBase (1)
WindowsBase.cs (1)
10[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.IO.FileFormatException))]
WindowsBase.Tests (2)
System\IO\Packaging\EncryptedPackageEnvelopeTests.cs (2)
43Assert.Throws<FileFormatException>(() => EncryptedPackageEnvelope.Open(stream)); 51Assert.Throws<FileFormatException>(() => EncryptedPackageEnvelope.Open(stream));