抱歉英语不好
我创建了一个访问表单,我希望当用户点击搜索按钮时, 带有文本框值的相关图像显示在未绑定的附件中。
和访问表单中的代码
Private Sub Command_SearchCP_Click()
Me.Text_FullName = Nz(DLookup("Fa_Name", "User_Details", "PersonalCode =" & Forms!Frm_LeaveRequest!Text_CP), 0)
Me.Text_Section = Nz(DLookup("Section", "User_Details", "PersonalCode =" & Forms!Frm_LeaveRequest!Text_CP), 0)
Me.Text_SuperName = Nz(DLookup("SuperName", "User_Details", "PersonalCode =" & Forms!Frm_LeaveRequest!Text_CP), 0)
Me.ProfilePicture.ControlSource = Nz(DLookup("ProfilePicture", "User_Details", "PersonalCode =" & Forms!Frm_LeaveRequest!Text_CP), 0)
End Sub
感谢您的善意和帮助