Results 1 to 3 of 3

Thread: Userform - pass textbox values to new Userform

  1. #1
    Neophyte OM1950's Avatar
    Join Date
    Dec 2014
    Location
    Northern Queensland
    Posts
    3
    Articles
    0

    Userform - pass textbox values to new Userform



    Register for a FREE account, and/
    or Log in to avoid these ads!

    I have 2 userforms – frmActionEntry, and frmActionClose. On occasions, when an action is being closed (frmActionClose) it may generate more actions (for instance closing an inspection as complete, but the inspection has found problems that must be added as new actions).
    On my frmActionClose, I have a textbox that asks “Number of New Corrective Actions from this activity”. If this is not zero, then when the initial action is closed, frmActionEntry opens, for the input of the new actions.
    All this works OK, but I want to link the new actions to the original action that generated them, by automatically populating several textboxes in frmActionEntry, with the values from frmActionClose - the values in txbNumber, txbSite, txbSection need to be passed from frmActionClose to frmActionEntry.
    I can’t work out how to do this – can someone advise me please.
    Thanks, OM1950

  2. #2
    Hi OM1950,
    What is the code you are using?
    possibly something like
    Code:
    frmActionEntry.textboxes.value=  frmActionClose.textboxes.value
    close frmActionClose
    frmActionEntry.show

  3. #3
    Neophyte OM1950's Avatar
    Join Date
    Dec 2014
    Location
    Northern Queensland
    Posts
    3
    Articles
    0
    Quote Originally Posted by pike View Post
    Hi OM1950,
    What is the code you are using?
    possibly something like
    Code:
    frmActionEntry.textboxes.value=  frmActionClose.textboxes.value
    close frmActionClose
    frmActionEntry.show
    Thanks Pike - I'll try this now. It seems obvious now that you have supplied the above code, but I hadn't thought of reading the values directly, and it should work, because I'm only hiding (not unloading) the "parent" form.

Tags for this Thread

Posting Permissions

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