If null then enter a value

  • Thread starter Thread starter fishqqq
  • Start date Start date
F

fishqqq

I have a macro that opens a form and I would like one of the fields to
be updated if it is null once the form opens,

I"m not sure what steps to take in the macro to perform this.

the form name is [AWB Main Info]
the field I want to update is [Origin City Code]
and if this field is null then I want to set it's value to "YYZ"

step one
Open form [AWB Main Info]

step two
Go To Control {Origin City Code]

at this point i don't know what to do

Can someone please shed some light on this for me?

Thank you
Steve
 
SetValue
    [Origin City Code]
    Nz([Origin City Code], "YYZ")

--

        Ken Snellhttp://www.accessmvp.com/KDSnell/


I have a macro that opens a form and I would like one of the fields to
be updated if it is null once the form opens,
I"m not sure what steps to take in the macro to perform this.
the form name is [AWB Main Info]
the field I want to update is [Origin City Code]
and if this field is null then I want to set it's value to "YYZ"
step one
Open form [AWB Main Info]
step two
Go To Control {Origin City Code]
at this point i don't know what to do
Can someone please shed some light on this for me?
Thank you
Steve

thanks this works perfectly
 
Back
Top