Results 1 to 5 of 5
  1. #1
    Join Date
    Oct 2002
    Posts
    18

    Unanswered: Createcontrol to tabpage

    I want to know how I get my created controls (using "createcontrol") to a tabpage.

    Thanks

  2. #2
    Join Date
    Aug 2002
    Location
    Charlotte NC
    Posts
    665
    Not sure what you mean, can you give us more detail?
    Jim

  3. #3
    Join Date
    Nov 2002
    Location
    San Francisco
    Posts
    251
    do you have your controls on the form, you created TAB and now you want to move all your controls to that tab?


    select your controls and CUT ctrl-x them, then select one tab from your tab control and PASTE ctrl-v



    jiri

  4. #4
    Join Date
    Oct 2002
    Posts
    18

    More details

    When I use the createcontrol methode I've to refer (according to the help example) to the FORM to were I want to put a object (say a textbox). This works just fine, when I run the VBA code it create's a textbox on the form I refered to.
    But I want to create the textbox only on one page of a tabcontrol.

    I think that or I treat the page of my tabcontrol as a form (but how)
    or the page of the tabcontrol is the parent of my textbox (but again, how do I declare this in the right way)
    The last possibility I can come-up with is that after I've created the textbox, I've to change a property of the textbox so it will be set as a member of the page of the tabcontrol

    This is the what the VBA help gives me:

    CreateControl(formname, controltype[, section[, parent[, columnname[, left[, top[, width[, height]]]]]]])


    thanks for your time so far
    Last edited by harmen; 01-02-03 at 15:19.

  5. #5
    Join Date
    Oct 2002
    Posts
    18

    Found the solution myself

    Yessssssss, found it,

    I have to use the parent section to place my textbox on a page of the tabcontrol.

    By putting:

    tbc.pages(i).name

    With tbc as tabcontrol and i as page index

    CreateControl(formname, controltype[, section[, parent[, columnname[, left[, top[, width[, height]]]]]]])

    Thanks for the your time

Posting Permissions

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