Hi All Again.
as the title says.
the error is:
An unhandled exception of type 'System.TypeInitializationException' occurred in PresentationCore.dll
Additional information: The type initializer for 'System.Windows.Automation.InvokePatternIdentifiers' threw an exception.
and through some googleing one person said that WPF will crash if any font is not installed correctly, but when i check out the reg intries, they all look fine.
<quate from="" some="" guy="">
This problem occurs because of improperly installed fonts in Windows. Open regedit.exe and navigate to the following:
HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts
You may notice that some fonts are registered with just their font name (example: times.ttf)
You may also notice that some fonts are registered with the full path to their location on the file system (example: c:\program files\appName\application\fonts\aaf.ttf)
WPF will break if any font is installed improperly. WPF only understands file names when it comes to locating fonts; it cannot navigate filesystem paths. Since ‘:’ and ‘\’ aren’t valid characters in a filename, WPF doesn’t know how to handle it and crashes.
You need to go into the registry and determine which fonts are improperly installed, then correct it by moving the font file to c:\windows\fonts and editing the registry entry to just include the font name (the OS knows to look at c:\windows\fonts).
I’ve scripted a fix for my organization but the code is proprietary. Simply write a script that parses each font name in the registry path noted above and strip out the full path (but keep the font file name). Then copy the font from its current location to c:\windows\fonts.
As well, check for invalid characters in any font that is in this registry branch. Any invalid character in the font name will cause WPF to crash.
br mode="hold" />
is there a fix for this ?
Thanks in Advance.
---edit---
Font Reg Entries