Results 1 to 2 of 2
  1. #1
    3 Star Lounger
    Join Date
    Jan 2001
    Posts
    254
    Thanks
    0
    Thanked 0 Times in 0 Posts

    synchronize 2 controls on a form

    How to synchronize two controls on a form

    I have a combo box to look up the CompanyName by typing the name of the customer.To this end the column width for the ID number is set to 0. It works fine however I want also that the Customer ID number is also shown,and if I do not set the ID number to 0, than I cannot look up by typing. To evade this problem I have put a second control on the form called CID and I want by coding to syncrhonize the two controls. Is there any possibility to synchronize the two controls ?

  2. #2
    3 Star Lounger
    Join Date
    Jan 2001
    Location
    USA
    Posts
    386
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: synchronize 2 controls on a form

    If the bound column of the combo box is the column containg the ID you can use something like

    me.CID = me.cboCompanyName

    in the click event of the CompanyName combo box.

    You can also refer directly to the column conating the ID

    me.CID = me.cboCompanyName.column(0)

    where the "0" is the column index of the ID field.



    Hope this helps.


    Richard Aheron
    raheron@hotmail.com
    Richard

Posting Permissions

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