BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

TIWEdit Uppercase

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Thirdparty Tools (IntraWeb)
View previous topic :: View next topic  
Author Message
Shane Holmes
Guest





PostPosted: Wed Apr 11, 2007 10:45 pm    Post subject: TIWEdit Uppercase Reply with quote



Is there a way to force all chars in TIWEdit to be Uppercase?
I need the chars in my TIWEdit to always be appercase.

I know I can pass them as uppercase later, using Uppercase(), but I would
like it to be visual in the TIWEdit as well.


Thanks

S
Back to top
Joel
Guest





PostPosted: Wed Apr 11, 2007 10:53 pm    Post subject: Re: TIWEdit Uppercase Reply with quote



Add javascript to do it or use TMS components

"Shane Holmes" <holmesshanea @ yahoo . com> wrote in message
news:461d1ea0$1 (AT) newsgroups (DOT) borland.com...
Quote:
Is there a way to force all chars in TIWEdit to be Uppercase?
I need the chars in my TIWEdit to always be appercase.

I know I can pass them as uppercase later, using Uppercase(), but I would
like it to be visual in the TIWEdit as well.


Thanks

S
Back to top
Shane Holmes
Guest





PostPosted: Wed Apr 11, 2007 11:52 pm    Post subject: Re: TIWEdit Uppercase Reply with quote



Thanks Joel

Any suggestions on how to do this using JavaScript?

Thanks
S

"Joel" <nowhere (AT) nowhere (DOT) com> wrote in message
news:461d20a4$1 (AT) newsgroups (DOT) borland.com...
Quote:
Add javascript to do it or use TMS components

"Shane Holmes" <holmesshanea @ yahoo . com> wrote in message
news:461d1ea0$1 (AT) newsgroups (DOT) borland.com...
Is there a way to force all chars in TIWEdit to be Uppercase?
I need the chars in my TIWEdit to always be appercase.

I know I can pass them as uppercase later, using Uppercase(), but I would
like it to be visual in the TIWEdit as well.


Thanks

S


Back to top
Joel
Guest





PostPosted: Thu Apr 12, 2007 7:30 pm    Post subject: Re: TIWEdit Uppercase Reply with quote

Here is an example

Put this in the Javascript property of the form

function mask(textbox,loc,delim,maxlen){

var

locs = loc.split(',');

str = textbox.value.substring(0,maxlen);

for (var i = 0; i <= locs.length; i++){

for (var k = 0; k <= str.length; k++){

if (k == locs[i]){

if (str.substring(k, k+1) != delim){

str = str.substring(0,k) + delim + str.substring(k,str.length)

}

}

}

}

textbox.value = str

}

then put this in the onblur on a iwedit scriptevents.

mask(IWEDIT1IWCL,"3,7","-", 12);


"Shane Holmes" <holmesshanea @ yahoo . com> wrote in message
news:461d2e30$1 (AT) newsgroups (DOT) borland.com...
Quote:
Thanks Joel

Any suggestions on how to do this using JavaScript?

Thanks
S

"Joel" <nowhere (AT) nowhere (DOT) com> wrote in message
news:461d20a4$1 (AT) newsgroups (DOT) borland.com...
Add javascript to do it or use TMS components

"Shane Holmes" <holmesshanea @ yahoo . com> wrote in message
news:461d1ea0$1 (AT) newsgroups (DOT) borland.com...
Is there a way to force all chars in TIWEdit to be Uppercase?
I need the chars in my TIWEdit to always be appercase.

I know I can pass them as uppercase later, using Uppercase(), but I
would like it to be visual in the TIWEdit as well.


Thanks

S




Back to top
Shane Holmes
Guest





PostPosted: Thu Apr 12, 2007 7:31 pm    Post subject: Re: TIWEdit Uppercase Reply with quote

THANKS!


"Joel" <nowhere (AT) nowhere (DOT) com> wrote in message
news:461e4271$2 (AT) newsgroups (DOT) borland.com...
Quote:
Here is an example

Put this in the Javascript property of the form

function mask(textbox,loc,delim,maxlen){

var

locs = loc.split(',');

str = textbox.value.substring(0,maxlen);

for (var i = 0; i <= locs.length; i++){

for (var k = 0; k <= str.length; k++){

if (k == locs[i]){

if (str.substring(k, k+1) != delim){

str = str.substring(0,k) + delim + str.substring(k,str.length)

}

}

}

}

textbox.value = str

}

then put this in the onblur on a iwedit scriptevents.

mask(IWEDIT1IWCL,"3,7","-", 12);


"Shane Holmes" <holmesshanea @ yahoo . com> wrote in message
news:461d2e30$1 (AT) newsgroups (DOT) borland.com...
Thanks Joel

Any suggestions on how to do this using JavaScript?

Thanks
S

"Joel" <nowhere (AT) nowhere (DOT) com> wrote in message
news:461d20a4$1 (AT) newsgroups (DOT) borland.com...
Add javascript to do it or use TMS components

"Shane Holmes" <holmesshanea @ yahoo . com> wrote in message
news:461d1ea0$1 (AT) newsgroups (DOT) borland.com...
Is there a way to force all chars in TIWEdit to be Uppercase?
I need the chars in my TIWEdit to always be appercase.

I know I can pass them as uppercase later, using Uppercase(), but I
would like it to be visual in the TIWEdit as well.


Thanks

S






Back to top
Farshad
Guest





PostPosted: Thu Apr 12, 2007 8:06 pm    Post subject: Re: TIWEdit Uppercase Reply with quote

In OnKeyPress event of IWEdit add this:

return uppercase();

In JavaScript of main form add the following:

function uppercase()
{
key = window.event.keyCode;
if ((key > 0x60) && (key < 0x7B))
window.event.keyCode = key-0x20;
return true;
}

However it only works in IE but the effect is immediate as the user types
the characters.

Quote:
Any suggestions on how to do this using JavaScript?

Thanks
S
Back to top
Shane Holmes
Guest





PostPosted: Thu Apr 12, 2007 8:41 pm    Post subject: Re: TIWEdit Uppercase Reply with quote

THANK YOU!


"Farshad" <farshad (AT) fmsoft (DOT) net> wrote in message
news:461e4b09 (AT) newsgroups (DOT) borland.com...
Quote:
In OnKeyPress event of IWEdit add this:

return uppercase();

In JavaScript of main form add the following:

function uppercase()
{
key = window.event.keyCode;
if ((key > 0x60) && (key < 0x7B))
window.event.keyCode = key-0x20;
return true;
}

However it only works in IE but the effect is immediate as the user types
the characters.

Any suggestions on how to do this using JavaScript?

Thanks
S

Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Thirdparty Tools (IntraWeb) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.