Results 1 to 4 of 4

Thread: Dynamic Add ?

  1. #1

    Thread Starter
    Addicted Member Tiovital's Avatar
    Join Date
    Apr 2000
    Posts
    249

    Post

    Hi,

    How can i add/rmove a control to a form dynamcally?
    Can add Form too?
    Can i copy a form with all the controls to another form dynmancally?

    Thanks


  2. #2
    Conquistador
    Join Date
    Dec 1999
    Location
    Australia
    Posts
    4,527
    1 question at a time:

    1. How can i add/rmove a control to a form dynamcally?
    Code:
    'If you already have a text box on your form, set its index
    'property to 0
    Dim maxID As Integer
    maxID = Command1.Count
    Load Command1(maxID)
    Command1(maxID).Visible = True
    Command1(maxID).Top = Command1(maxID - 1).Top + command1(maxID - 1).Height 100
    2. Can add Form too?
    Code:
    Dim frmNew As New Form1
    Load frmNew
    frmNew.Show
    3. Can i copy a form with all the controls to another form dynmancally?

    They already will be on your new form, as frmNew is just a new copy of Form1 ok

    good luck

    i hope i helped you

  3. #3

    Thread Starter
    Addicted Member Tiovital's Avatar
    Join Date
    Apr 2000
    Posts
    249

    Hi,

    da_silvy - David - Thnkx

  4. #4
    Conquistador
    Join Date
    Dec 1999
    Location
    Australia
    Posts
    4,527

    Thumbs up

    so it worked

Posting Permissions

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



Click Here to Expand Forum to Full Width