SHFB 1.9.5.0 Fails to Load SHFB Project Files

Topics: User Forum
Nov 4, 2012 at 9:57 AM

I have upgraded to SHFB 1.9.5.0 to check whether one of my two issues with 1.9.4.0 (cf. http://shfb.codeplex.com/discussions/396570 and http://shfb.codeplex.com/discussions/396570) might have disappeared with that version.

However, when opening the SHFB GUI and when trying to load an SHFB project, the following error message appears:

The framework definitions were not loaded. Does a valid definition file exist (%DXROOT%\ProductionTools\Frameworks.xml)?

The project is not loaded and the property inspector in the Project Properties tab remains empty.

The DXROOT variable does exist on my system as a system variable; it points to the path of the Sandcastle installation, and the indicated file exists and looks like an Xml file with much information (I can't tell whether it's valid in the terms of whatever causes the error message, though).

What can I do to find out how to solve that problem, so I can get back to trying to solve my two other problems?

Thanks in advance!

Coordinator
Nov 6, 2012 at 2:35 AM

If it's reporting "%DXROOT%" in the name, it isn't resolving the environment variable.  You may just need to reboot so that it takes effect.

Eric

 

Nov 6, 2012 at 7:36 PM

Ah, indeed. Sorry, didn't think of that possibility because the variable would already show up in Windows' control panel, so I thought it had sufficiently "sunken in" by then.

The previous issues with HTML Help Compiler crashing etc. are still there with 1.9.5.0, though :-(

Nov 15, 2012 at 8:35 AM

I'm having the same issue.  I get this message:

 

System.InvalidOperationException: The framework definitions were not loaded.  Does a valid definition file exist (C:\Program Files (x86)\Sandcastle\ProductionTools\Frameworks.xml)?

   at SandcastleBuilder.Utils.Design.FrameworkVersionTypeConverter.get_DefaultFramework()

   at SandcastleBuilder.Utils.SandcastleProject..ctor()

   at SandcastleBuilder.Utils.MSBuild.BuildHelp.Execute()

 

However, %DXROOT% is equal to 'D:\Program Files (x86)\Sandcastle\'.

 

When Sandcastle was installed on the C drive, I had the exact same message except with D:\ being the drive was expected on.  Any ideas?  It seems to always be looking on the wrong drive like there's a file somewhere that's out of step with the environment variable.

Nov 15, 2012 at 8:46 AM

If it helps, that error is immediately preceeded by 'SHFB: Unable to get executing project:  Unable to obtain matching project from the global collection.  The specified project will be loaded but command line property overrides will be ignored.'

Coordinator
Nov 15, 2012 at 4:08 PM

The message about the project not being in the global collection typically means you're not using MSBuild 4.0.  Make sure you're using the MSBuild.exe from the .NET 4.0 framework folder and also that your SHFB project contains a ToolsVersion="4.0" attribute on the root Project element.  Opening the project in Visual Studio or the standalone GUI and saving it is usually enough to upgrade the project to the latest schema version if it needs it.

As noted above, a reboot may be needed for the system to pick up the environment variable changes after the initial installation.  If you added the environment variable manually, make sure you added it as a system environment variable rather than a user environment variable too.

Eric