473,385 Members | 1,875 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 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 12686
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: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.