Populate fields when another field = (1 Viewer)

Number11

Member
Local time
Today, 09:57
Joined
Jan 29, 2020
Messages
607
I am looking for a way to auto complete some fields if another field =

So i have a combi Box they can select:
1. Out Of Stock
2. Dispatched
3. Back Order

would like Dispatch Date to show when Out Of Stock is selected N/A in that date field ect
 

Number11

Member
Local time
Today, 09:57
Joined
Jan 29, 2020
Messages
607
I have tried on After Update..

If Me.Status> "Out Of Stock" Then Me.Dispatch Date Notes= "N/A"

did work?
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Today, 17:57
Joined
May 7, 2009
Messages
19,175
what is the Name of the textbox to update:

If Me.Status> "Out Of Stock" Then Me![Dispatch Date Notes]= "N/A"

if the datatype of [Dispatch Date] is Date/Time, then you cannot assign "N/A" to this field.
 

Number11

Member
Local time
Today, 09:57
Joined
Jan 29, 2020
Messages
607
what is the Name of the textbox to update:

If Me.Status> "Out Of Stock" Then Me![Dispatch Date Notes]= "N/A"

if the datatype of [Dispatch Date] is Date/Time, then you cannot assign "N/A" to this field.
Thanks its just a text box as notes - tried your suggestion but still doesnt work
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Today, 17:57
Joined
May 7, 2009
Messages
19,175
use = when comparing instead of >.
 

bob fitz

AWF VIP
Local time
Today, 09:57
Joined
May 23, 2011
Messages
4,717
What is the Row Source property setting of the combo box?
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Today, 17:57
Joined
May 7, 2009
Messages
19,175
see post #6 and the Bound Column of your combo?
 

Number11

Member
Local time
Today, 09:57
Joined
Jan 29, 2020
Messages
607
All working now... using

If Me.Status ="Out Of Stock" Then Me! [Dispatch Date Notes]= "N/A"

But i now want to add only change the field [Dispatch Date Notes] to "" if its showing as "N/A" so if its already showing "Dispatched", leave it?
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Today, 17:57
Joined
May 7, 2009
Messages
19,175
If Me.Status ="Out Of Stock" Then Me! [Dispatch Date Notes]= Nz(Me! [Dispatch Date Notes], "N/A")
 

Users who are viewing this thread

Top Bottom