|
tech
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Proper CaseI have a textbox, just one, on a form. I type info into it and transfer
it to another field. How would I get that first textbox to automatically format to Proper Case, I see access can do lower case, it can do upper case....I searched the net for a simple solution, but everything I tried doesn't seem to work for whatever reason, perhaps lack of experience on my part :) Any suggestions would be appreciated. Thanks DS On Wed, 23 Feb 2005 18:14:11 -0500, DS wrote:
> I have a textbox, just one, on a form. I type info into it and transfer On the Form's control's AfterUpdate event code:> it to another field. How would I get that first textbox to > automatically format to Proper Case, I see access can do lower case, it > can do upper case....I searched the net for a simple solution, but > everything I tried doesn't seem to work for whatever reason, perhaps > lack of experience on my part :) > Any suggestions would be appreciated. > Thanks > DS Me![ControlName] = StrConv([ControlName],3) Note: this will incorrectly capitalize some words which contain more than one capital, i.e. O'Brien, MacDonald, IBM, Jones-Smith, ABC, etc., and incorrectly capitalize some words that should not have any capitals, or whose capitaliztion depends upon usage, such as e. e. cummings, abc, van den Steen. Then some names can be capitalized in more than one manner, depending upon personal preference, i.e. O'Connor and O'connor, McDaniels and Mcdaniels, etc. are both correct. You can create a table of exceptions and have the code use DLookUp with a message if one of the exception words is found. -- Fred Please only reply to this newsgroup. I do not reply to personal email. fredg wrote:
Show quote > On Wed, 23 Feb 2005 18:14:11 -0500, DS wrote: Thank You, I tried it and it doesn't seem to work...I need it to Update > > >>I have a textbox, just one, on a form. I type info into it and transfer >>it to another field. How would I get that first textbox to >>automatically format to Proper Case, I see access can do lower case, it >>can do upper case....I searched the net for a simple solution, but >>everything I tried doesn't seem to work for whatever reason, perhaps >>lack of experience on my part :) >>Any suggestions would be appreciated. >>Thanks >>DS > > > On the Form's control's AfterUpdate event code: > Me![ControlName] = StrConv([ControlName],3) > > Note: this will incorrectly capitalize some words which contain more > than one capital, i.e. O'Brien, MacDonald, IBM, Jones-Smith, ABC, > etc., and incorrectly capitalize some words that should not have any > capitals, or whose capitaliztion depends upon usage, such as e. e. > cummings, abc, van den Steen. > Then some names can be capitalized in more than one manner, depending > upon personal preference, i.e. O'Connor and O'connor, McDaniels and > Mcdaniels, etc. are both correct. > > You can create a table of exceptions and have the code use DLookUp > with a message if one of the exception words is found. as I type. I made a second control with the string in it and that seems to work except I can't use the keyboard though. Maybe it needs to go on another Event? Thank You DS On Wed, 23 Feb 2005 19:40:41 -0500, DS wrote:
Show quote > fredg wrote: No.. it doesn't need to go in another event. And it's not supposed to>> On Wed, 23 Feb 2005 18:14:11 -0500, DS wrote: >> >>>I have a textbox, just one, on a form. I type info into it and transfer >>>it to another field. How would I get that first textbox to >>>automatically format to Proper Case, I see access can do lower case, it >>>can do upper case....I searched the net for a simple solution, but >>>everything I tried doesn't seem to work for whatever reason, perhaps >>>lack of experience on my part :) >>>Any suggestions would be appreciated. >>>Thanks >>>DS >> >> On the Form's control's AfterUpdate event code: >> Me![ControlName] = StrConv([ControlName],3) >> >> Note: this will incorrectly capitalize some words which contain more >> than one capital, i.e. O'Brien, MacDonald, IBM, Jones-Smith, ABC, >> etc., and incorrectly capitalize some words that should not have any >> capitals, or whose capitaliztion depends upon usage, such as e. e. >> cummings, abc, van den Steen. >> Then some names can be capitalized in more than one manner, depending >> upon personal preference, i.e. O'Connor and O'connor, McDaniels and >> Mcdaniels, etc. are both correct. >> >> You can create a table of exceptions and have the code use DLookUp >> with a message if one of the exception words is found. > Thank You, I tried it and it doesn't seem to work...I need it to Update > as I type. I made a second control with the string in it and that seems > to work except I can't use the keyboard though. Maybe it needs to go on > another Event? > Thank You > DS update as you type. It changes the data in the field when you exit the control, as it should. -- Fred Please only reply to this newsgroup. I do not reply to personal email. fredg wrote:
Show quote > On Wed, 23 Feb 2005 19:40:41 -0500, DS wrote: Ok, Thanks..still a newie at this.> > >>fredg wrote: >> >>>On Wed, 23 Feb 2005 18:14:11 -0500, DS wrote: >>> >>> >>>>I have a textbox, just one, on a form. I type info into it and transfer >>>>it to another field. How would I get that first textbox to >>>>automatically format to Proper Case, I see access can do lower case, it >>>>can do upper case....I searched the net for a simple solution, but >>>>everything I tried doesn't seem to work for whatever reason, perhaps >>>>lack of experience on my part :) >>>>Any suggestions would be appreciated. >>>>Thanks >>>>DS >>> >>>On the Form's control's AfterUpdate event code: >>>Me![ControlName] = StrConv([ControlName],3) >>> >>>Note: this will incorrectly capitalize some words which contain more >>>than one capital, i.e. O'Brien, MacDonald, IBM, Jones-Smith, ABC, >>>etc., and incorrectly capitalize some words that should not have any >>>capitals, or whose capitaliztion depends upon usage, such as e. e. >>>cummings, abc, van den Steen. >>>Then some names can be capitalized in more than one manner, depending >>>upon personal preference, i.e. O'Connor and O'connor, McDaniels and >>>Mcdaniels, etc. are both correct. >>> >>>You can create a table of exceptions and have the code use DLookUp >>>with a message if one of the exception words is found. >> >>Thank You, I tried it and it doesn't seem to work...I need it to Update >>as I type. I made a second control with the string in it and that seems >>to work except I can't use the keyboard though. Maybe it needs to go on >>another Event? >>Thank You >>DS > > > No.. it doesn't need to go in another event. And it's not supposed to > update as you type. It changes the data in the field when you exit the > control, as it should. DS |
|||||||||||||||||||||||