vba - How to associate a field in a form to a specific value in a table -
i'm new @ vba programming. have table contains 'id' , 'bidder' , form has 1 field 'text1', i'm trying make field display 'bidder' value 'id'=2.
i thinking make query , store value in field, not sure if can that,
text1.value= docmd.runsql "select bidder bidder_v3 (([id])='2')"
is working, bad idea, don't know how solve one.
i appreciate help. thank you!
if want display single value use dlookup function
text1.value= dlookup("bidder_vs","[bidder]","[id]='2'")
this okay single value but, preferably, form based on query retrieves data need display.
note docmd.runsql
doesn't return anything, designed execute action-queries, such update queries.
Comments
Post a Comment