Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Custom IS Command Question
Message
From
02/06/2005 20:17:15
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows 2000 SP4
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01019615
Message ID:
01019639
Views:
40
This message has been marked as a message which has helped to the initial question of the thread.
>What I am trying to do is create a custom entry (command?) in my intellisense table that does NOT start the beginning of a command line. For example, if I type:
>
>obet< space bar >
>
>I want IS to return something like:
>
>BETWEEN ~value1~ AND val2
>
>for the "between" SQL syntax for Oracle. If I can get ~value1~ selected for replacement that would be a bonus.
>
>Syntax in the SQL command like:
>
>fbet
>
>could return the VFP syntax for between like
>
>BETWEEN(~fieldname~, value1, value2)
>
>I know I could just use BETW for that one, but I wanted to illustrate a point here.
>
>Any tips on how to make this work are appreciated.


Hi Mark,

I'm not sure if this what you want, but you can modify it to suit your needs:

Add a new blank record in foxcode.dbf, put this:

Type: U
Abbrev: obet
Cmd: {}
Data:
LParameters to_Foxcode

Local l_Value1, l_Value2

If (to_Foxcode.Location != 1)   && not in editor
   Return ''
endif

to_Foxcode.ValueType = 'V'
l_Value1 = InputBox( 'Input Value1', 'Custom IS', '' )
l_Value2 = InputBox( 'Input Value2', 'Custom IS', '' )

Return 'Between ' + l_Value1 + ' and ' + l_Value2
You can do the same for the other

HTH
Herman
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform