Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Inputmask as I type...
Message
From
23/07/2008 01:35:00
Dragan Nedeljkovich
Now officially retired
Zrenjanin, Serbia
 
 
To
22/07/2008 23:33:02
Chris Sund
Silhouette Solutions
Utah, United States
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Vista
Miscellaneous
Thread ID:
01333323
Message ID:
01333382
Views:
9
>Hi Dragan,
>
>Would mind explaining a little further. I'm trying to hack your response with my limited knowledge of using the Left() operator within the interactive change. Would you mind showing me a little sample code. I didn't understand how to determine the "m" and the "n" or m-n??
>
>Your time is very appreciated!

I don't have any code, but... let's try:
* interactivechange
dodefault()
cMask="99-999-9-99-999-999-9" && can't remember what it really was
cTxt=this.text
nLen=len(cTxt)
nMaskLen=nLen
cTempMask=left(cMask,nLen)
do while occurs("9", cTempMask)<nLen
   nMaskLen=nMaskLen+1c
   cTempMask=left(cMask,nMaskLen)
enddo
this.function="R"
this.inputmask=cTempMask
Haven't tried this, so this is under the assumption that this.text doesn't include the dashes if .function="R"; if it does, then cTxt=chrtran(this.text, "-", "").

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform