Results 1 to 7 of 7
  1. #1
    3 Star Lounger
    Join Date
    Jul 2001
    Location
    ASKER, Norway
    Posts
    277
    Thanks
    6
    Thanked 0 Times in 0 Posts

    Userform and Multipage control (W2000 SP-1 WinNT)

    Problem focusing to a text box with a template containing a multipage, 4 pages.

    I have a message prompting for info to be written into a textbox when an option button is clicked. Clicking the OK button in the Msgbox gives me a fault message saying that the textbox is not available since it is not enabled or hidden.

    The particular Tab is not visible when this question arise.
    How can I open the particular Tab in the multipage in order to visualize the textbox such that I can write into it?
    Is there a parameter or a code I can put into the procedure such that the tab opens?

    Hope for help!

    Thanks

    Best regards
    Bj

  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: Userform and Multipage control (W2000 SP-1 WinNT)

    I didn't re-read <A target="_blank" HREF=http://www.wopr.com/cgi-bin/w3t/showflat.pl?Cat=&Board=vb&Number=66412&page=&view= &sb=&o=&fpart=all&vc=1>this long thread</A>, but please check it out and let us know if you have new or different experiences trying to set focus.

  3. #3
    3 Star Lounger
    Join Date
    Jul 2001
    Location
    ASKER, Norway
    Posts
    277
    Thanks
    6
    Thanked 0 Times in 0 Posts

    Re: Userform and Multipage control (W2000 SP-1 WinNT)

    Hi,

    I had not read the long thread either. But I think I have a different situation. I'm able to set focus to text boxes which are visible in the Userform but not to a text box which is on a non-visible page in a Multipage containing 4 pages. The focusing is functioning if I open the page where the text box is placed.

    I use a an option box as follows:

    If optKursMed.Value = True Then
    If txbF

  4. #4
    3 Star Lounger
    Join Date
    Feb 2001
    Location
    Leigh on Sea, Essex, England
    Posts
    263
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Userform and Multipage control (W2000 SP-1 WinNT)

    I think you want to use the code

    <font face="Georgia">UserForm.Multipage.Value = n</font face=georgia>

    where n is the page number of the page you wish to show, numbering from zero (and replacing UserForm and Multipage with your own names, obviously). Put this in appropriate places, and it should do the trick.

    I use this when I have a single form with a number of pages, but different toolbar buttons for quick access - so for example, one button will load the form and then select one page, while another will also load the form but will select a different one.


    Regards,

  5. #5
    3 Star Lounger
    Join Date
    Jul 2001
    Location
    ASKER, Norway
    Posts
    277
    Thanks
    6
    Thanked 0 Times in 0 Posts

    Re: Userform and Multipage control (W2000 SP-1 WinNT)

    Thanks a lot Stewart. I will try it out and let you know the result later on.

    Thanks and
    best regards
    Bj

  6. #6
    3 Star Lounger
    Join Date
    Jul 2001
    Location
    ASKER, Norway
    Posts
    277
    Thanks
    6
    Thanked 0 Times in 0 Posts

    Re: Userform and Multipage control (W2000 SP-1 WinNT)

    Hi,

    Tried it but it did not work the way I expected. Well, may be I haven't coded correctly, though I did not get any error messages. The focus point (insertion point) got placed in the correct text box, but the page was not visible and therefore not accessible to the user unless the page tab is clicked.

    I already have the Userform open and the Multipage inside the form is open on page0. When I hit the option box, situated elsewhere in the form, the code should open page1, also having Tabindex 1.

    Regards
    Bj

  7. #7
    3 Star Lounger
    Join Date
    Feb 2001
    Location
    Leigh on Sea, Essex, England
    Posts
    263
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Userform and Multipage control (W2000 SP-1 WinNT)

    Not too sure why it wouldn't work if I understood you properly - it probably means I haven't!

    Can you post your current code snippet, or attach a spreadsheet? I'll have a look at it if you can.

    Regards,

Posting Permissions

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