Results 1 to 2 of 2
  1. #1
    Join Date
    Nov 2002
    Posts
    13

    Unanswered: Link Forms to registers in drop down list box

    Hi there, I need to link a form to a value in a list box, so when user selects a value in the list a form (different for each value) opens. The value is stored in a table. I imagined adding a hyperlink field in this table, but could not get sufficient information about hyperlinking a value to a form.

    Thanks once more.

    Luis.

  2. #2
    Join Date
    Sep 2002
    Location
    Land of OZ
    Posts
    173

    Re: Link Forms to registers in drop down list box

    Originally posted by laqa
    Hi there, I need to link a form to a value in a list box, so when user selects a value in the list a form (different for each value) opens. The value is stored in a table. I imagined adding a hyperlink field in this table, but could not get sufficient information about hyperlinking a value to a form.

    Thanks once more.

    Luis.
    Assumbly each value will open a different form. I guess your easiet solution would be to add a field in the table for the formname.

    On the listbox, add both the value and the fornname fields. Change the column count to 2 and column widths to 3cm;0cm so that the formname does not display on the listbox to users.

    On te afterupdate event of the listbox add the following line of code.
    Dim strFormName as String

    strFormName = listboxname.column(1)
    Docmd.OpenForm strFormName

    This should launch the appropriate form.

    Hope that this helps
    Mona
    Mona
    ________________________________
    Life is too short to be sane or sensible. Weird people rule and normal people suck

Posting Permissions

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