ShovelinFishHeads
Registered User.
- Local time
- Today, 03:08
- Joined
- Aug 4, 2016
- Messages
- 57
After reading through many threads here about copying and pasting via code and trying many examples of various strategies to do this, I need to get some advice. My attempts at this are not working.
I have mailing address information for "Carriers" and also for personnel of Carriers with a second table dedicated for personnel contact info. One-to-many relationship.
I want to allow for users to copy/paste, by way of a command button, the Carrier's "HQ" address into the employee's address when/if the employee doesn't use something different.
Forms are set up such that Carriers is one "main" form with Personnel in a subform under a tab strip control.
Currently trying to make this work:
Private Sub Command57_Click()
Dim strAddress1 As String
Forms![Carriers Main Form]!Address1 = strAddress1
strAddress1 = Forms![Carrier Personnel]!Address1
End Sub
Which results in => Run-time error '2450':
Microsoft Access cannot find the referenced form "Carrier Personnel".
Selected the subform (Carrier Personnel) by clicking on it one time while in design mode for the main (parent) form.
The property sheet says from the top: Selection type: Subform/Subreport; then the list box below that says "Carrier Personnel"
Link Master Fields shows CarrierID; Link Child Fields shows CarrierID; Filter On Empty Master shows Yes; Enabled shows Yes; Locked shows No.
Would love to get some feedback on why this isn't working; Or any advice.
Thanks everyone......
I have mailing address information for "Carriers" and also for personnel of Carriers with a second table dedicated for personnel contact info. One-to-many relationship.
I want to allow for users to copy/paste, by way of a command button, the Carrier's "HQ" address into the employee's address when/if the employee doesn't use something different.
Forms are set up such that Carriers is one "main" form with Personnel in a subform under a tab strip control.
Currently trying to make this work:
Private Sub Command57_Click()
Dim strAddress1 As String
Forms![Carriers Main Form]!Address1 = strAddress1
strAddress1 = Forms![Carrier Personnel]!Address1
End Sub
Which results in => Run-time error '2450':
Microsoft Access cannot find the referenced form "Carrier Personnel".
Selected the subform (Carrier Personnel) by clicking on it one time while in design mode for the main (parent) form.
The property sheet says from the top: Selection type: Subform/Subreport; then the list box below that says "Carrier Personnel"
Link Master Fields shows CarrierID; Link Child Fields shows CarrierID; Filter On Empty Master shows Yes; Enabled shows Yes; Locked shows No.
Would love to get some feedback on why this isn't working; Or any advice.
Thanks everyone......