Proper() statement for a multi-line field
Hi,
I have a small function to tidy up address data from a mix of lower/upper/proper case formats.
The Address field is a Multi Line text field in the form, and I find that when I run this script, it only applies Proper case to the first line, and lower case to subsequent lines in the field.
For example:
ADDRESS LINE 1
ADDRESS LINE 2
TOWN
CITY
becomes:
Address Line 1
address line 2
town
city
where I am expecting:
Address Line 1
Address Line 2
Town
City
My initial guess is this is a bug, does anyone have a way around this in order to apply Proper case to all words, not just those in the first line?
Thanks in advance!
- void AddressFormat()
- {
- for each S in Sites [ID != 0]
- {
- SiteAddress = S.Address;
- SiteAddress = proper(SiteAddress);
- S.Address = SiteAddress;
- }
- }