HOWTO: Text.DefaultValue = Table.Value

H

Hans

Hi,

I want to set the Text.DefaultValue = The first row and first column
of an table entry.

Or ist there another easy way to set a Textbox to a certain Value of a
table entry?


Greets
Hans
 
A

Arvin Meyer

Hans said:
Hi,

I want to set the Text.DefaultValue = The first row and first column
of an table entry.

Or ist there another easy way to set a Textbox to a certain Value of a
table entry?

You can use DLookup or a recordset to return the value you want, then set
the default value to that:

Dim x
x = DLookup("Whatever", tblWhatever", "ID='" & Me.txtID & "'")

Me.txtBox.DefaultValue = x
--
Arvin Meyer, MCP, MVP
Microsoft Access
Free Access downloads:
http://www.datastrat.com
http://www.mvps.org/access
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top