Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Textbox Auto Complete
Message
From
19/12/2005 03:49:45
 
 
To
19/12/2005 03:34:20
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 6 SP5
OS:
Windows XP
Network:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01079101
Message ID:
01079102
Views:
36
Use the KeyPress, something like this:
LPARAMETERS nKeyCode, nShiftAltCtrl
Do case
  case this.value="B"
    Nodefault
    This.value="BILL"
    This.selstart=len(this.value)
  case this.value="S"
    Nodefault
    This.value="BILLS"
    This.selstart=len(this.value)
  case this.value="Q"
    Nodefault
    This.value="CHEQUE #"
    This.selstart=len(this.value)
Endcase
NB! Why do you use Alltrim when you assign a value?


>Dear Experts
>
>I want to fill up text1 with following method
>If I write B in text1 then should display BILL and so on.
>And cursor must remain in text1 and should go to the end of the word.
>
>I wrote following codes that work fine on the lostfocus of text1.
>But I do not want to use lostfocus.
>
>Please help
>
>case1=alltrim(thisform.text1.value)
>DO case
>CASE case1="B"
>	this.VALUE=alltrim("BILL")
>CASE case1="S"
>	this.VALUE=alltrim("BILLS")
>CASE case1="Q"
>	this.VALUE=alltrim("CHEQUE # ")
>ENDCASE
>
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform