Results 1 to 4 of 4
  1. #1
    New Lounger
    Join Date
    Aug 2002
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Nasty Little command bar (Office 2000)

    Hello all,
    I have a problem. I have a user form docked to the bottom of the word
    window. and I need to use a dummy command bar to create a space in the
    Dockbottom command bar. Its all working nice but wit a nasty little problem.
    The command bar shows up on top of the userform. I have used the statement
    word.customizationcontext = activedocument before creating the dummy
    commandbar. And the funny thing is that when the there is just a single
    document this dosent happen ,ie the command bar lies in tha background and
    the form is visible fully , but If I open another document and the switch
    back to the previous document, then the problem occurs.
    Is there any way where I can make the command bar stay behind the Form. I f
    i dont user the customizationcontext statement It works fine but creates the
    cmmand bar for all documents, and If I use the customizationcontext this
    happens. I am going nuts .
    Please tell me if there is a work around

    Regards,
    <img src=/S/confused.gif border=0 alt=confused width=15 height=20>

  2. #2
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: Nasty Little command bar (Office 2000)

    I don't know how you docked a UserForm to the bottom of the Word window, but I gather that once it loses focus, it ends up behind the toolbars. You could try setting an event sink using the WindowActivate event of the Application object. Having never done this, I can't suggest specific code, but it seems to be the most logical way to determine whether a user has switched back to your target window.

  3. #3
    New Lounger
    Join Date
    Aug 2002
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Nasty Little command bar (Office 2000)

    Hi jscher2000,
    Thanks for the reply. About docking the form. It was a bit tricky I was to;d that it wasnt possible to directly do it. So thought why not try in directly. So created a command bar on the bottom and used couple of api functions to set the parent of the form to where I wanted it to be.
    Any way I will try what you have suggested and get back with problems ;-) or with a thanks as the case will be.
    Regards,
    Reets

  4. #4
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: Nasty Little command bar (Office 2000)

    [Responding to a private message that it didn't work.]

    Can you post your project? Use WinZip or another zipping program if needed to get the thing under 100K.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •