472,951 Members | 1,802 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,951 software developers and data experts.

input mask

hello

how would i make an input mask that only makes the first letter a
capitol one?

i've been playing around and testing various masks, also tried the
wizard, but i've had no luck.

could anyone help, many thanks in advance.
Nov 12 '05 #1
6 12640
DFS
You might do better my putting some code to change the capitalization in the
Exit or AfterUpdate event:

me.txtField = ucase(left(me.txtField,1)) & lcase(mid(me.txtField,2))
"dude" <sp*******@yahoo.com> wrote in message
news:c0**************************@posting.google.c om...
hello

how would i make an input mask that only makes the first letter a
capitol one?

i've been playing around and testing various masks, also tried the
wizard, but i've had no luck.

could anyone help, many thanks in advance.

Nov 12 '05 #2
This quick try worked for me:

I put this as the input mask value:
?<????
This input mask is for upto five optional characters, the first one, if
entered, will be capitalized.

HTH

Mike Krous

"dude" <sp*******@yahoo.com> wrote in message
news:c0**************************@posting.google.c om... hello

how would i make an input mask that only makes the first letter a
capitol one?

i've been playing around and testing various masks, also tried the
wizard, but i've had no luck.

could anyone help, many thanks in advance.

Nov 12 '05 #3
See bottom of the posting

"Mike Krous" <m.krous@nospam_comcast.net> wrote in message
news:ur********************@comcast.com...
This quick try worked for me:

I put this as the input mask value:
?<????


This input mask is for upto five optional characters, the first one, if
entered, will be capitalized.

HTH

Mike Krous

"dude" <sp*******@yahoo.com> wrote in message
news:c0**************************@posting.google.c om...
hello

how would i make an input mask that only makes the first letter a
capitol one?

i've been playing around and testing various masks, also tried the
wizard, but i've had no luck.

could anyone help, many thanks in advance.



That works for me - can anyone suggest how to auto set it to Title Format
(i.e. capitalise 1st letter and any letter separated by a space!) WITHOUT
using code?

If this is not possible - what would the code (or pseudo-code) look like?
Like this pseudo-code?

string=UCase(Left$(string,1))+string
for i=2 to len(string)
IF mid$(string,i,1) = " " Then
string=left$(string,1,i)+
UCase(mid$(string,i+1,1)+mid$(string,i+2,len(strin g))
next i


Nov 12 '05 #4
without code would look like this. but wouldn't you want to separate this
into two fields?
?\ <????
the \ character says display the next character as a literal so I put a
space next. I must say tho, this information is readily available in the
Microsoft Help files if you press F1 in the input mask property.

HTH

Mike Krous

"Nick Marshall" <Nick Ma******@NOSPAM.COM> wrote in message
news:vs************@corp.supernews.com... See bottom of the posting

"Mike Krous" <m.krous@nospam_comcast.net> wrote in message
news:ur********************@comcast.com...
This quick try worked for me:

I put this as the input mask value:
?<????


This input mask is for upto five optional characters, the first one, if
entered, will be capitalized.

HTH

Mike Krous

"dude" <sp*******@yahoo.com> wrote in message
news:c0**************************@posting.google.c om...
hello

how would i make an input mask that only makes the first letter a
capitol one?

i've been playing around and testing various masks, also tried the
wizard, but i've had no luck.

could anyone help, many thanks in advance.



That works for me - can anyone suggest how to auto set it to Title Format
(i.e. capitalise 1st letter and any letter separated by a space!) WITHOUT
using code?

If this is not possible - what would the code (or pseudo-code) look like?
Like this pseudo-code?

string=UCase(Left$(string,1))+string
for i=2 to len(string)
IF mid$(string,i,1) = " " Then
string=left$(string,1,i)+
UCase(mid$(string,i+1,1)+mid$(string,i+2,len(strin g))
next i

Nov 12 '05 #5
> (i.e. capitalise 1st letter and any letter separated by a space!)
woops, sorry missed that, not just a space but letters seperated by
space....

strX = StrConv("my text proper case", vbProperCase)
(strX now equals "My Text Proper Case")

if you want mixed cases goto
http://www.mvps.org/access/strings/str0008.htm

Mike Krous
"Mike Krous" <m.krous@nospam_comcast.net> wrote in message
news:3t********************@comcast.com...
without code would look like this. but wouldn't you want to separate this
into two fields?
?\ <????


the \ character says display the next character as a literal so I put a
space next. I must say tho, this information is readily available in the
Microsoft Help files if you press F1 in the input mask property.

HTH

Mike Krous

"Nick Marshall" <Nick Ma******@NOSPAM.COM> wrote in message
news:vs************@corp.supernews.com...
See bottom of the posting

"Mike Krous" <m.krous@nospam_comcast.net> wrote in message
news:ur********************@comcast.com...
This quick try worked for me:

I put this as the input mask value:
>?<????

This input mask is for upto five optional characters, the first one, if entered, will be capitalized.

HTH

Mike Krous

"dude" <sp*******@yahoo.com> wrote in message
news:c0**************************@posting.google.c om...
> hello
>
> how would i make an input mask that only makes the first letter a
> capitol one?
>
> i've been playing around and testing various masks, also tried the
> wizard, but i've had no luck.
>
> could anyone help, many thanks in advance.


That works for me - can anyone suggest how to auto set it to Title Format (i.e. capitalise 1st letter and any letter separated by a space!) WITHOUT using code?

If this is not possible - what would the code (or pseudo-code) look like? Like this pseudo-code?

string=UCase(Left$(string,1))+string
for i=2 to len(string)
IF mid$(string,i,1) = " " Then
string=left$(string,1,i)+
UCase(mid$(string,i+1,1)+mid$(string,i+2,len(strin g))
next i


Nov 12 '05 #6

"Mike Krous" <m.krous@nospam_comcast.net> wrote in message
news:GM********************@comcast.com...
(i.e. capitalise 1st letter and any letter separated by a space!)

woops, sorry missed that, not just a space but letters seperated by
space....

strX = StrConv("my text proper case", vbProperCase)
(strX now equals "My Text Proper Case")

if you want mixed cases goto
http://www.mvps.org/access/strings/str0008.htm

Mike Krous

<B I G S N I P>

In the immortal words of one Homer Simpson "Doh!" - is it really that
simple? As I always tell my children, you don't know what you don't know,
because you don't know if you know it or not!!

Thanks for the hint

Nick Marshall
Nov 12 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Ellen Manning | last post by:
I've got an A2K database with a link to a table in another A2K database. This linked table contains SSN formatted with the SSN input mask. I'm trying to use a dlookup using this linked table. ...
9
by: Paul | last post by:
hi, is there an input mask i could use on a report to do the following: (1) if i enter "THISISATEST" on my form, i want the text box on my report to display: "T H I S I S A T E S T". (2) if...
2
by: johnp | last post by:
Hi, Our Tech department updated users to Office 2003 this week. Now the input mask in one of the applications is showing up as: (###) ###-### The input mask wizard works correctly when I...
7
by: F. Michael Miller | last post by:
I have a db with Access front end, sql back, linked tables. I need to be able to change input masks at the table level in code. Any ideas? Thanks!
3
by: AA Arens | last post by:
When I want the first character of a field to be Uppercased, I need to make an input mask, like >L< followed by ??????? for example. But this mask creates ____ in an unfilled field, which I don't...
9
by: msnews.microsoft.com | last post by:
Hello. How can I set input mask for TextBox? Or can I use for mask input some other control?
1
ADezii
by: ADezii | last post by:
The following characters define an Input Mask: Character - Description 0 - Digit (0 to 9, entry required, plus and minus signs not allowed). 9 - Digit or space (entry not required, plus...
2
by: sparks | last post by:
Can you do this. We have some fields with double set and an input mask of fixed decimal place 2 input mask ###.## works great..
7
desklamp
by: desklamp | last post by:
I'm a total Access newbie, please bear with me! Using Win2K/Access 2003. I'm trying to create a table in which I can store IP addresses and other information. According to Microsoft, there is no...
0
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
0
by: Mushico | last post by:
How to calculate date of retirement from date of birth
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 4 Oct 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
0
by: Aliciasmith | last post by:
In an age dominated by smartphones, having a mobile app for your business is no longer an option; it's a necessity. Whether you're a startup or an established enterprise, finding the right mobile app...
0
tracyyun
by: tracyyun | last post by:
Hello everyone, I have a question and would like some advice on network connectivity. I have one computer connected to my router via WiFi, but I have two other computers that I want to be able to...
3
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be using a very simple database which has Form (clsForm) & Report (clsReport) classes that simply handle making the calling Form invisible until the Form, or all...
1
by: Teri B | last post by:
Hi, I have created a sub-form Roles. In my course form the user selects the roles assigned to the course. 0ne-to-many. One course many roles. Then I created a report based on the Course form and...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 1 Nov 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM) Please note that the UK and Europe revert to winter time on...
3
by: nia12 | last post by:
Hi there, I am very new to Access so apologies if any of this is obvious/not clear. I am creating a data collection tool for health care employees to complete. It consists of a number of...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.