From: DM - NPS on 20 May 2010 17:07 I have 2 forms, 1 that is used to enter data and 1 that is a giant number pad. If a person double clicks in one of the fields on the data entry form it will open the number pad form and they can use the number pad to enter the data. This process works great. However, I want to have an unbound box at the top of the number pad form that shows which field has the focus on the data entry form. Any ideas? Thanks in advance.
From: Jeanette Cunningham on 20 May 2010 23:33 Easy. Get the name of the field when the user clicks the control. If the control name is the same as the field name, that's easy. Otherwise you can store the field name in the control's tag. Pass the name of the field as OpenArgs to the code that opens the number pad form. In the Open event of the number pad form, you get the field name from the openargs and use it to set the value for the unbound textbox. In the double click event: DoCmd.OpenForm "frmNumberPad", , , , , , Me.ActiveControl.Name Or DoCmd.OpenForm "frmNumberPad", , , , , , Me.ActiveControl.Tag In the Open event of the number pad form: If Not IsNull(Me.OpenArgs) Then Me.NameOfUnboundtextBox = Me.OpenArgs End If Note: replace my object names with your own. Jeanette Cunningham MS Access MVP -- Melbourne Victoria Australia "DM - NPS" <DMNPS(a)discussions.microsoft.com> wrote in message news:8F9B4F51-85CF-4DCC-BF22-83F1D5FB5E82(a)microsoft.com... >I have 2 forms, 1 that is used to enter data and 1 that is a giant number > pad. If a person double clicks in one of the fields on the data entry > form > it will open the number pad form and they can use the number pad to enter > the > data. This process works great. > > However, I want to have an unbound box at the top of the number pad form > that shows which field has the focus on the data entry form. Any ideas? > > Thanks in advance.
|
Pages: 1 Prev: Open Add Printer dialog... Next: Check for null values before updating table from form |