Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.1k views
in Technique[技术] by (71.8m points)

ms access - VBA to autofill image control from table/query column

I have a form that auto-populates text boxes from a table/query when a line in a listbox is clicked.

enter image description here

There is an image control to the right for the same 'Customer' selection.

I have the VBA correct for the auto population of the text boxes but I've not done this for images before.

My existing VBA:

With lst_Customers
    txtCustomerCode.Value = .Column(0)
    txtCustomerName.Value = .Column(1)
    txtCustomerContact.Value = .Column(2)
    txtHomeAddress.Value = .Column(3)
    txtWorkAddress.Value = .Column(4)
End With

This is what the columns of the table/query looks like:

enter image description here

What is the VBA to add the image to the form in this process?

question from:https://stackoverflow.com/questions/65830018/vba-to-autofill-image-control-from-table-query-column

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...