Rick Strahl's Weblog  

Wind, waves, code and everything in between...
.NET • C# • Markdown • WPF • All Things Web
Contact   •   Articles   •   Products   •   Support   •   Advertise
Sponsored by:
Markdown Monster - The Markdown Editor for Windows

Help Builder 4.05 improves .NET support


:P
On this page:

Ughhh. I meant for this update to be a really minor update that was to fix a few UI bugs that have been reported over the last few weeks since Help Builder has been released. Well, it turned out that a lot of things got updated and fixed in this new release.

 

The brunt of the work went into .NET class imports. My original goal was to merely update Help Builder's existing templates to match more closely with the MSDN templates. In the process I realized that there were a number of fairly rough edges in the .NET class imports that Help has been doing and a few features that could be much nicer.

 

The most obvious change now is that the new templates use formatting more similar to MSDN. The content of the class member topics is also more accurate now pulling in signatures properly formatted for the targeted import language chosen – you can choose to import either in C# or VB.NET format. Type names are now language specific instead of using the BCL types as before. This functionality has also been extended to the two way tools accessible from within the VS.NET editor where you can pull XML comment content into Help Builder and push Help Builder content into XML comments (for C# or if you’re using a third party tool for VB as well).

 

Class headers now also show the inheritance tree and link to any types available in the current project or to any MSDN content in the System and Microsoft Namespaces. I wrote about one other feature the other day – pulling in only currently implemented interfaces as opposed to all interfaces the class hierarchy implements. Constructor information also got a rework – constructors are now pulled in as a separate topic(s) and got a new topic type CLASSCONSTRUCTOR.

 

Combine these enhancements to the import and add the support for the more streamlined templates and you have what I think is a much nicer and cleaner class import mechanism.

 

 

Truth is that a lot of these import features should have been there before. Part of the reason they weren’t is that Help Builder is not a .NET only tool, so it caters to both .NET and other tools like COM and FoxPro developers who can also import classes and the like. Many of the features I implemented now deal with very .NET specific functionality and this is why it’s taken a bit to get here while at the same making sure that non-.NET imports continue to work well also. I’d be curious to know what you think.

 

There is one thing still missing (and I’m getting to that) and that’s custom attributes, but it’s coming.

 

And yes I hear the obvious question: Why not use NDoc? NDoc does a great job of component documentation and it’s free. Yes, but NDoc is not a full solution like Help Builder. You can’t generate ‘the rest’ of your documentation – samples, walk throughs, architecture charts etc. with NDoc. Help Builder lets you build a full documentation solution and manage it in one place.

 

Any thoughts on this?

 

HTML Editing Enhancements

There have still been some issues around the HTML Editing functionality with the control occasionally loosing context and (gulp) failing that cause an Application Error dialog in Help Builder. Thanks to bug reports from our users I’ve been able to track down a number of these issues more closely.

 

I’ve reworked the way the control refreshes by using a more resource intensive, but more conservative approach to refreshing content ( brute force – reload the entire control ) and that has provided a much more stable environment for the control.

 

SQL Database View Imports

Late last night as I was getting ready to wrap things up for distribution I got an email from Alan Scharf asking for what now seems a fairly obvious request: Can we get Views and UDF()s imported from SQL Server? Duh, how did I not think of that before. I didn’t get around to the User function imports but Views are now imported along with tables and stored procedures.

 

Miscellanous fixes and improvements

Michael Schwing pointed out that Help Builder did not respect the locale settings of the environment it was running under. Eeeek – an obvious omission on my part to enable locale matching support in the app made Help Builder always run American locale format. Simple fix, but thanks Michael for pointing out something I would probably never have caught!

 

Help Builder Extension

Help Builder now also has a small PRG file that optionally is launched at startup if it exists. The idea is to provide an initialization hook for developers to inject (FoxPro) commands at startup of the application. This allows a lot of flexibility to set the environment as well as the possibility to access any COM capable tools and make them globally available. If you are familiar with Fox code you can also write custom UDF()s here that can be called from the HTML templates. Note that although Help Builder uses FoxPro code it’s totally trivial to hook up any other COM capable environment. For example you can create a wrapper Fox function for a .NET COM  object:

 

FUNCTION ParseAssembly(lcFileName)

 

loRef = CREATEOBJECT("wwReflection.TypeParser")

loRef.cAssemblyName = lcFileName

loRef.cAssemblyXmlDoc = FORCEEXT(lcFileName,"xml")

 

loRef.GetAllObjects()

 

RETURN loRef

 

Once this function is defined in the HelpBuilder_Extension.prg file you can now call ParseAssembly directly from your HTML Templates and use the loRef object in your template. The templates could already run Fox code and access COM objects in this fashion, but by putting it in this extension file the programming model is a bit easier as you can build common functions that can be reused in all templates.

 

There are a also a few new generic functions that are embeddable into templates such as MDSNLink, and improvements to the child table functions that allow easy embedding of custom child topic tables similar to the member list in the figure above. Help Builder uses some of these internally in the templates (the ClassHeader template for example) as well as for custom lists such as generated for StoredProcedure imports from SQL Server.

 

 

So as you can see, lots of new stuff, for what was meant to be a simple update <g>. The new version is now online at http://www.west-wind.com/wwhelp/ - if you already have 4.0 installed you can use the Help Menu’s Check for Latest version to grab the latest version.

 

Please not that in order to take advantage of some of the new import features you will need to update your templates in existing projects.


The Voices of Reason


 

Rick Strahl's Web Log
October 15, 2006

# Web Browser Control Flicker - Rick Strahl's Web Log

Getting the Web Browser Control to not flicker and handle Editing with dialogs popping up to save changes takes some work. Here is a dirty solution for Visual FoxPro that works.

West Wind  © Rick Strahl, West Wind Technologies, 2005 - 2024