Improve the help system of the generated wmi functions

Jul 25, 2012 at 10:46 AM

Hi Kirk,

on my german OS (win7 64 bit) the fields Overview and Description of the created wmi functions are empty.

Is it possible to copy the class description during module generation to the respective functions?

You should get the description via:

Get-WmiObject -List "Win32_*" | foreach {
((Get-WmiObject -List $_.Name -Amended).Qualifiers | where {$_.Name -eq "Description"}).Value



Jul 25, 2012 at 2:42 PM

Hi Andreas,

I'm harvesting the Description field from WMI using the amended qualifiers already, and injecting it into the help for the command.  You can see an example of this in Get-Help Get-PingStatus.  The second paragraph was not written by comes directly from WMI.

Are you indicating that you want the Description property of the function objects themselves to be set to the WMI description attribute?  I know cmdlets and functions have a Description property, but I've rarely if ever seen anyone use it in PowerShell.

Also, what is the Overview field you are referring to?

Thanks for asking these questions, they're going to help me make this module even better!

Kirk out.

Jul 25, 2012 at 3:44 PM

Hi Kirk,

for the most functions the name is self explanatory but not for all :)

I thought it could be a good idea to have the amended qualifiers in the description. On my german OS the Description is empty. With Overview field I mean the Overview part.

Maby this screenshot makes it clear.



Jul 25, 2012 at 4:06 PM

Hi Andreas,

Now I see what you're talking about.  That's just a bug.  I'm writing the help xml files to an en-us folder, but for other locales like German, I need to write them to the appropriate folder instead.

Could you check inside wmifx\root\cimv2\en-us and open the Get-PingStatus-Help.xml file?  I'd like to know if it has the correct German synopsis/overview and description that you're expecting to see.  Note that at the moment this will have English text in the description as well because some of the strings are being written in English right now...I need to pull those out into a string table (and then I need someone to give me translations in other languages, like German for example...want to do some translation?).

If the help file looks like it is there, could you try this:

1. Unload wmifx.

2. Rename the en-us folder as de-de.

3. Reload wmifx.

4. Try getting help for Get-PingStatus.

I want to know if this is simply a folder issue (aside from the English language strings that I need to push into a string table for translation).


Kirk out.

Jul 26, 2012 at 11:40 AM

Hi Kirk,

here is the content of the get-pingstatus-help.xml:

Here is a screenshot how the description in the help is shown after I renamed the folder to de-de:

It looks better than before. Thanks.

I will think about your translation request and will give you a feedback because I'm not the best translator.

Could you upload this string file somewhere in the source code area and point me to the file?  In this case I can better evaluate how much translation work needs to be done :)





Jul 30, 2012 at 10:42 PM

Thank you once again Andreas.  I have updated (locally and checked into CodePlex) the wmix module so that it now generates help in a folder matching the current UI culture so that you'll at least get English help from the commands that are generated.  Actually, on a German system, you'll get English and German mixed because the help pulled from WMI will be German and until I get a German translation for my string tables (also checked in), the rest of the text around that will be English.  The string tables are checked in, so I'll put together something on here regarding translation and document what is required.  The good news: it should be really, really easy.

Kirk out.