If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Show Data from another Form
I have two Forms (and Tables): BankProfile Form, and Addresses Form.
The Addresses Form has a two digit State Code in it. When I show the BankProfile Form, I would like to show the State Code from Addresses. I don't know how to do this. Is the control on BankProfile Unbound, or bound to what? I have a combo box with the following SQL view, but I don't want to select a value, I want it to fill in automatically. SELECT tblAddresses.AddrID, tblAddresses.State, tblAddresses.BankID FROM tblBanks INNER JOIN tblAddresses ON tblBanks.BankID = tblAddresses.BankID WHERE (((tblAddresses.BankID)=[Forms]![BankProfile]![BankID])); Thanks for you suggestions... |
#2
|
|||
|
|||
Show Data from another Form
esee -
You can have an unbound text box on your BankProfile Form, and put this in it (assuming BankID is the name of a control on your BankProfile form that has the bankid in it - adjust as needed): =DLookup("State","tblAddresses","[BankID] = " & Me.BankID) If BankID is a text field (rather than numeric, use this: =DLookup("State","tblAddresses","[BankID] = '" & Me.BankID & "'") -- Daryl S "esee" wrote: I have two Forms (and Tables): BankProfile Form, and Addresses Form. The Addresses Form has a two digit State Code in it. When I show the BankProfile Form, I would like to show the State Code from Addresses. I don't know how to do this. Is the control on BankProfile Unbound, or bound to what? I have a combo box with the following SQL view, but I don't want to select a value, I want it to fill in automatically. SELECT tblAddresses.AddrID, tblAddresses.State, tblAddresses.BankID FROM tblBanks INNER JOIN tblAddresses ON tblBanks.BankID = tblAddresses.BankID WHERE (((tblAddresses.BankID)=[Forms]![BankProfile]![BankID])); Thanks for you suggestions... . |
#3
|
|||
|
|||
Show Data from another Form
On Mar 23, 11:14*am, Daryl S wrote:
esee - You can have an unbound text box on your BankProfile Form, and put this in it (assuming BankID is the name of a control on your BankProfile form that has the bankid in it - adjust as needed): =DLookup("State","tblAddresses","[BankID] = " & Me.BankID) If BankID is a text field (rather than numeric, use this: =DLookup("State","tblAddresses","[BankID] = '" & Me.BankID & "'") -- Daryl S "esee" wrote: I have two Forms (and Tables): BankProfile Form, and Addresses Form. The Addresses Form has a two digit State Code in it. When I show the BankProfile Form, I would like to show the State Code from Addresses. I don't know how to do this. *Is the control on BankProfile Unbound, or bound to what? I have a combo box with the following SQL view, but I don't want to select a value, I want it to fill in automatically. SELECT tblAddresses.AddrID, tblAddresses.State, tblAddresses.BankID FROM tblBanks INNER JOIN tblAddresses ON tblBanks.BankID = tblAddresses.BankID WHERE (((tblAddresses.BankID)=[Forms]![BankProfile]![BankID])); Thanks for you suggestions... . Yes Sir, that's it. Thank you... |
Thread Tools | |
Display Modes | |
|
|