1 Reply Latest reply on Jan 21, 2013 1:59 PM by philmodjunk

    Auto fill

    thong127

      Title

      Auto fill

      Post

           Hello All,

            

           Happy 2013,

           I have a field Departments (Department is a dropdown list)  and Department Code (10, 20,30,40,50...). How can I make that if I choose a Department, the Department Code will Automatically fill its corresponding code.

           Departments                      Code

           Formulation                           20

           Production                              10

           Admin                                       30

            

           Thank you.

        • 1. Re: Auto fill
          philmodjunk

               Create a table, DepartmentCodes, with three records and two fields in each record: The fields will be Department and Code. define a relationship like this:

               YourTable::Departments = DepartmentCodes::Code

               Define a value list of Deparments with the "use values from a field" option. Select DepartmentCodes::Code for the first field and DeparmentCodes::Department for the second field. You can hide the first field if you want.

               Format YourTable::Departments as drop down list. Put DepartmentCodes::Department on the layout next to the drop down list.

               When you select a department from the dorp down list, the department name will appear in the DepartmentCodes::Department field and the number will appear in your drop down field.