thevillageinn
Technical User
I have a text box on my form which combines First and Last name fields. Sometimes either name has extra padding which I want to remove before displaying the data.
I was using the following functions in the Control Source for this field:
=Nz(Trim$([firstname]),""
& " " & Nz(Trim$([lastname]),""
This works just fine as long as there is data in both fields, but when there is no data, the 'Nz' function is not properly filling in the null, even when I provide a value (something like: Nz(Trim$([firstname]), "n/a"
)
Am I trying to do too many functions? I thought I needed the Nz function to prevent errors if/when I had a null value in one of the fields, but it's failing me.
Any suggestions?
Many thanks-
-Dan
I was using the following functions in the Control Source for this field:
=Nz(Trim$([firstname]),""
This works just fine as long as there is data in both fields, but when there is no data, the 'Nz' function is not properly filling in the null, even when I provide a value (something like: Nz(Trim$([firstname]), "n/a"
Am I trying to do too many functions? I thought I needed the Nz function to prevent errors if/when I had a null value in one of the fields, but it's failing me.
Any suggestions?
Many thanks-
-Dan