• Pop-up help for form, HelpContextID oddity – Word 2010

    Home » Forums » AskWoody support » Productivity software by function » Visual Basic for Applications » Pop-up help for form, HelpContextID oddity – Word 2010

    Author
    Topic
    #482148

    I’m having trouble with pop-up help on a userform.

    I set a HelpContextID for the form itself, so if someone clicks What’s This, then clicks off a control, they will get an overview of what the form is for. This doesn’t work anymore (although it did through Word 2003). Now if you click on the form itself, you get thrown into Office 2010’s very unhelpful programming help.

    Needless to say, that’s not where I want to send my users.

    I got around this by placing a transparent label as the back layer of the form, with all other controls in front, and giving the label an ID. This worked fine. But.

    The form I’m having an issue with is used for two different but very similar purposes, with the labels being rewritten and the HelpContextIDs changed at run-time. All the IDs are seamlessly changed except the one for the label. It’s throwing an error that the member does not exist. Oh yes it does.

    Has anyone else had any experience with this? And does anyone have any suggestions? I’ve tried substituting the label with a frame but it’s a no-go for several reasons, including that it just doesn’t look right.

    I’m between a rock and a hard place, here. If anyone has suggestions I’ll welcome them. In the meantime, I’m thinking of just duping the form and dropping the run-time shenanigans.

    Thanks, Kim

    Viewing 0 reply threads
    Author
    Replies
    • #1324962

      Well, I think I know why I can’t change the HelpContextID for the label control. According to at least one book, the HelpContextID is not a property of the image or label controls.

      Except that it is listed as a property when the label is selected, and you can set it, and you can associate pop-up help with it. But apparently changing it at run-time exposes the sham, vba knows the label does not have that property and therefore refuses to set it. Hence the “Object or Data member does not exist” error.

      So, little did I know that I was exploiting a useful bug. I’ve decided to stop thinking about this and just create a new form.

      However, I am still cranky that Word 2010/Windows 7 doesn’t handle clicking the UserForm the way that Word 2007/Windows XP does — with a simple “No Help topic is associated with this item” message. I’m beginning to think that this is a hole in Windows 7, which didn’t ship with WinHelp32 support and required an update (I’m sure they thought no one would still want to use that old thing).

      Kim :huh:

    Viewing 0 reply threads
    Reply To: Pop-up help for form, HelpContextID oddity – Word 2010

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: