I am trying to find out how to define filters for Dynamic Help that respond to user-defined attributes within the HTML source files (as opposed to the context-sensitive messages emitted by the current object in focus inside Visual Studio). For full details, see below; any advice at all (including "this cannot be done", should this be the case) would be greatly appreciated. Feel free to write to me at edwarddotgrahamatugsdotcom.
Thanks,
Ed Graham
P.S. This post is a copy of the one I sent to the Visual Studio Extensibility forum.
+ + + + + + + + + + + + + + + + + + + + + + + + +
My company has recently integrated its documentation within Visual Studio help (as an .HxS file), such that the user manuals are available for browsing in the Contents pane and HTML documentation describing the function headers is available through Dynamic Help (triggered by typing the name of the function within the source code editor). We release a new version of our product twice a year and reissue all of the documentation with each release.
In order to filter results when more than one version of the documentation is installed, I have inserted a new attribute name "UGSProdName" and value xxx inside each of our documentation (HTML) files, where xxx represents the version number (and hence changes with each release). This works perfectly for browsing the user manuals but has no effect on Dynamic Help, which I understand filters according to what the developer is doing (e.g., what type of file they are editing) rather than any attributes I have defined in the HTML source files (for the documentation). Is there any way that I can create a filter for Dynamic Help that will respond to the value of "UGSProdName" Or any other way of filtering out previous versions of our documentation from Dynamic Help I have looked into the idea of defining the attributes in a .HxA file in the installer project (using the Help Integration Wizard) but it seems to me that this shouldn't be necessary.

How should I define filters that work for dynamic help in VS2003/5?
Toadkillerdog
Ed,
We've discussed this over email, but here's some info for the benefit of other forums readers.
Thanks!
- Jeremy Jones
===
When your software is loaded, it needs to push an attribute to the Active Context bag. Let's say that attribute is named "GrahamAttribute". The value associated with that attribute needs to be different for each version of his software. For example:< xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />
GrahamAttribute=version1
GrahamAttribute=version2
GrahamAttribute=version3
GrahamAttribute=version4
So your software needs to push GrahamAttribute=version1 to the Active Context bag when it is loaded. At the same time, all the Help topics that go with version 1 of your software need to have GrahamAttribute=version1 assigned to them. And so on for the other versions. In this way, the three "wrong" versions of a Help topics should be excluded from the Dynamic Help window in any given context.