Advertisement
pebriana

Interactive Search / Autocomplete in a Text Box

May 11th, 2012
142
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ****** VFP9 with SP 1
  2. Public oform1
  3.  
  4. oform1=Newobject("form1")
  5. oform1.Show
  6. Return
  7.  
  8. **************************************************
  9. *-- Form:         form1 (\imaginecorp\form11.scx)
  10. *-- ParentClass:  form
  11. *-- BaseClass:    form
  12. *-- Time Stamp:   02/02/07 01:25:12 AM
  13. *
  14. Define Class form1 As Form
  15.  
  16.  
  17.     Top = 3
  18.     Left = 48
  19.     Height = 100
  20.     Width = 375
  21.     DoCreate = .T.
  22.     ShowTips = .T.
  23.     Caption = "Auto Complete"
  24.     Name = "Form1"
  25.  
  26.  
  27.     Add Object command1 As CommandButton With ;
  28.         Top = 67, ;
  29.         Left = 278, ;
  30.         Height = 27, ;
  31.         Width = 84, ;
  32.         Caption = "Close", ;
  33.         TabIndex = 2, ;
  34.         Name = "Command1"
  35.  
  36.  
  37.     Add Object label1 As Label With ;
  38.         AutoSize = .T., ;
  39.         Caption = "Company", ;
  40.         Height = 17, ;
  41.         Left = 60, ;
  42.         Top = 25, ;
  43.         Width = 55, ;
  44.         TabIndex = 3, ;
  45.         Name = "Label1"
  46.  
  47.  
  48.     Add Object text1 As TextBox With ;
  49.         Format = "K", ;
  50.         Height = 23, ;
  51.         Left = 120, ;
  52.         SelectOnEntry = .T., ;
  53.         TabIndex = 1, ;
  54.         Top = 20, ;
  55.         Width = 207, ;
  56.         Name = "Text1"
  57.  
  58.  
  59.     Procedure Load
  60.         If Used("customer")
  61.             Use In customer
  62.         Endif
  63.         **** Do not need to do this if there is an Index
  64.         Set Exclusive On
  65.         ************************************************
  66.         Select 0
  67.         Use Home()+"samples\data\customer.dbf"
  68.         ************************************************
  69.         Index On company Tag company
  70.         Set Order To Tag company
  71.         ************************************************
  72.     Endproc
  73.  
  74.  
  75.     Procedure command1.Click
  76.         Thisform.Release
  77.     Endproc
  78.  
  79.  
  80.     Procedure text1.InteractiveChange
  81.         With This
  82.             If (Lastkey() >= 32 And Lastkey() <= 127)
  83.                 .nIDSelStart = Icase(.nIDSelStart >= 0 And Lastkey() = 127,.nIDSelStart - 1,;
  84.                     .nIDSelStart < 0,0,;
  85.                     .nIDSelStart + 1)
  86.                 Select customer
  87.                 coldtag = Tag()
  88.                 Set Order To Tag company
  89.                 Locate For Substr(Alltrim(Upper(customer.company)),1,.nIDSelStart) = ;
  90.                     Upper(Substr(This.Value,1,.nIDSelStart))
  91.                 ***** Could use a SEEK() as well
  92.                 If  Found()
  93.                     This.Value = customer.company
  94.                 Else
  95.                     If !Empty(This.Value)
  96.                         .nIDSelStart = This.SelStart
  97.                     Else
  98.                         .nIDSelStart = 0
  99.                     Endif
  100.                 Endif
  101.                 This.SelStart = .nIDSelStart
  102.                 Set Order To Tag (coldtag)
  103.             Endif
  104.         Endwith
  105.         This.SelLength = Iif(!Empty(This.Value),(Len(Alltrim(This.Value))-(This.nIDSelStart)),1)
  106.     Endproc
  107.  
  108.  
  109.     Procedure text1.Init
  110.         If !Pemstatus(This,"nIDSelStart",5)
  111.             This.AddProperty("nIDSelStart",0)
  112.         Endif
  113.     Endproc
  114.  
  115.  
  116. Enddefine
  117. *
  118. *-- EndDefine: for
  119. **************************************************
  120. *-- Form:         form1 (\imaginecorp\form11.scx)
  121. *-- ParentClass:  form
  122. *-- BaseClass:    form
  123. *-- Time Stamp:   02/02/07 01:25:12 AM
  124. *
  125. Define Class form1 As Form
  126.  
  127.  
  128.     Top = 3
  129.     Left = 48
  130.     Height = 100
  131.     Width = 375
  132.     DoCreate = .T.
  133.     ShowTips = .T.
  134.     Caption = "Auto Complete"
  135.     Name = "Form1"
  136.  
  137.  
  138.     Add Object command1 As CommandButton With ;
  139.         Top = 67, ;
  140.         Left = 278, ;
  141.         Height = 27, ;
  142.         Width = 84, ;
  143.         Caption = "Close", ;
  144.         TabIndex = 2, ;
  145.         Name = "Command1"
  146.  
  147.  
  148.     Add Object label1 As Label With ;
  149.         AutoSize = .T., ;
  150.         Caption = "Company", ;
  151.         Height = 17, ;
  152.         Left = 60, ;
  153.         Top = 25, ;
  154.         Width = 55, ;
  155.         TabIndex = 3, ;
  156.         Name = "Label1"
  157.  
  158.  
  159.     Add Object text1 As TextBox With ;
  160.         Format = "K", ;
  161.         Height = 23, ;
  162.         Left = 120, ;
  163.         SelectOnEntry = .T., ;
  164.         TabIndex = 1, ;
  165.         Top = 20, ;
  166.         Width = 207, ;
  167.         Name = "Text1"
  168.  
  169.  
  170.     Procedure Load
  171.         If Used("customer")
  172.             Use In customer
  173.         Endif
  174.         **** Do not need to do this if there is an Index
  175.         Set Exclusive On
  176.         ************************************************
  177.         Select 0
  178.         Use Home()+"samples\data\customer.dbf"
  179.         ************************************************
  180.         Index On company Tag company
  181.         Set Order To Tag company
  182.         ************************************************
  183.     Endproc
  184.  
  185.  
  186.     Procedure command1.Click
  187.         Thisform.Release
  188.     Endproc
  189.  
  190.  
  191.     Procedure text1.InteractiveChange
  192.         With This
  193.             If (Lastkey() >= 32 And Lastkey() <= 127)
  194.                 .nIDSelStart = Icase(.nIDSelStart >= 0 And Lastkey() = 127,.nIDSelStart - 1,;
  195.                     .nIDSelStart < 0,0,;
  196.                     .nIDSelStart + 1)
  197.                 Select customer
  198.                 coldtag = Tag()
  199.                 Set Order To Tag company
  200.                 Locate For Substr(Alltrim(Upper(customer.company)),1,.nIDSelStart) = ;
  201.                     Upper(Substr(This.Value,1,.nIDSelStart))
  202.                 ***** Could use a SEEK() as well
  203.                 If  Found()
  204.                     This.Value = customer.company
  205.                 Else
  206.                     If !Empty(This.Value)
  207.                         .nIDSelStart = This.SelStart
  208.                     Else
  209.                         .nIDSelStart = 0
  210.                     Endif
  211.                 Endif
  212.                 This.SelStart = .nIDSelStart
  213.                 Set Order To Tag (coldtag)
  214.             Endif
  215.         Endwith
  216.         This.SelLength = Iif(!Empty(This.Value),(Len(Alltrim(This.Value))-(This.nIDSelStart)),1)
  217.     Endproc
  218.  
  219.  
  220.     Procedure text1.Init
  221.         If !Pemstatus(This,"nIDSelStart",5)
  222.             This.AddProperty("nIDSelStart",0)
  223.         Endif
  224.     Endproc
  225.  
  226.  
  227. Enddefine
  228. *
  229. *-- EndDefine: for
  230. *-- Form:         form1 (\imaginecorp\form11.scx)
  231. *-- ParentClass:  form
  232. *-- BaseClass:    form
  233. *-- Time Stamp:   02/02/07 01:25:12 AM
  234. *
  235. Define Class form1 As Form
  236.  
  237.  
  238.     Top = 3
  239.     Left = 48
  240.     Height = 100
  241.     Width = 375
  242.     DoCreate = .T.
  243.     ShowTips = .T.
  244.     Caption = "Auto Complete"
  245.     Name = "Form1"
  246.  
  247.  
  248.     Add Object command1 As CommandButton With ;
  249.         Top = 67, ;
  250.         Left = 278, ;
  251.         Height = 27, ;
  252.         Width = 84, ;
  253.         Caption = "Close", ;
  254.         TabIndex = 2, ;
  255.         Name = "Command1"
  256.  
  257.  
  258.     Add Object label1 As Label With ;
  259.         AutoSize = .T., ;
  260.         Caption = "Company", ;
  261.         Height = 17, ;
  262.         Left = 60, ;
  263.         Top = 25, ;
  264.         Width = 55, ;
  265.         TabIndex = 3, ;
  266.         Name = "Label1"
  267.  
  268.  
  269.     Add Object text1 As TextBox With ;
  270.         Format = "K", ;
  271.         Height = 23, ;
  272.         Left = 120, ;
  273.         SelectOnEntry = .T., ;
  274.         TabIndex = 1, ;
  275.         Top = 20, ;
  276.         Width = 207, ;
  277.         Name = "Text1"
  278.  
  279.  
  280.     Procedure Load
  281.         If Used("customer")
  282.             Use In customer
  283.         Endif
  284.         **** Do not need to do this if there is an Index
  285.         Set Exclusive On
  286.         ************************************************
  287.         Select 0
  288.         Use Home()+"samples\data\customer.dbf"
  289.         ************************************************
  290.         Index On company Tag company
  291.         Set Order To Tag company
  292.         ************************************************
  293.     Endproc
  294.  
  295.  
  296.     Procedure command1.Click
  297.         Thisform.Release
  298.     Endproc
  299.  
  300.  
  301.     Procedure text1.InteractiveChange
  302.         With This
  303.             If (Lastkey() >= 32 And Lastkey() <= 127)
  304.                 .nIDSelStart = Icase(.nIDSelStart >= 0 And Lastkey() = 127,.nIDSelStart - 1,;
  305.                     .nIDSelStart < 0,0,;
  306.                     .nIDSelStart + 1)
  307.                 Select customer
  308.                 coldtag = Tag()
  309.                 Set Order To Tag company
  310.                 Locate For Substr(Alltrim(Upper(customer.company)),1,.nIDSelStart) = ;
  311.                     Upper(Substr(This.Value,1,.nIDSelStart))
  312.                 ***** Could use a SEEK() as well
  313.                 If  Found()
  314.                     This.Value = customer.company
  315.                 Else
  316.                     If !Empty(This.Value)
  317.                         .nIDSelStart = This.SelStart
  318.                     Else
  319.                         .nIDSelStart = 0
  320.                     Endif
  321.                 Endif
  322.                 This.SelStart = .nIDSelStart
  323.                 Set Order To Tag (coldtag)
  324.             Endif
  325.         Endwith
  326.         This.SelLength = Iif(!Empty(This.Value),(Len(Alltrim(This.Value))-(This.nIDSelStart)),1)
  327.     Endproc
  328.  
  329.  
  330.     Procedure text1.Init
  331.         If !Pemstatus(This,"nIDSelStart",5)
  332.             This.AddProperty("nIDSelStart",0)
  333.         Endif
  334.     Endproc
  335.  
  336.  
  337. Enddefine
  338. *
  339. *-- EndDefine: for
  340. *-- ParentClass:  form
  341. *-- BaseClass:    form
  342. *-- Time Stamp:   02/02/07 01:25:12 AM
  343. *
  344. Define Class form1 As Form
  345.  
  346.  
  347.     Top = 3
  348.     Left = 48
  349.     Height = 100
  350.     Width = 375
  351.     DoCreate = .T.
  352.     ShowTips = .T.
  353.     Caption = "Auto Complete"
  354.     Name = "Form1"
  355.  
  356.  
  357.     Add Object command1 As CommandButton With ;
  358.         Top = 67, ;
  359.         Left = 278, ;
  360.         Height = 27, ;
  361.         Width = 84, ;
  362.         Caption = "Close", ;
  363.         TabIndex = 2, ;
  364.         Name = "Command1"
  365.  
  366.  
  367.     Add Object label1 As Label With ;
  368.         AutoSize = .T., ;
  369.         Caption = "Company", ;
  370.         Height = 17, ;
  371.         Left = 60, ;
  372.         Top = 25, ;
  373.         Width = 55, ;
  374.         TabIndex = 3, ;
  375.         Name = "Label1"
  376.  
  377.  
  378.     Add Object text1 As TextBox With ;
  379.         Format = "K", ;
  380.         Height = 23, ;
  381.         Left = 120, ;
  382.         SelectOnEntry = .T., ;
  383.         TabIndex = 1, ;
  384.         Top = 20, ;
  385.         Width = 207, ;
  386.         Name = "Text1"
  387.  
  388.  
  389.     Procedure Load
  390.         If Used("customer")
  391.             Use In customer
  392.         Endif
  393.         **** Do not need to do this if there is an Index
  394.         Set Exclusive On
  395.         ************************************************
  396.         Select 0
  397.         Use Home()+"samples\data\customer.dbf"
  398.         ************************************************
  399.         Index On company Tag company
  400.         Set Order To Tag company
  401.         ************************************************
  402.     Endproc
  403.  
  404.  
  405.     Procedure command1.Click
  406.         Thisform.Release
  407.     Endproc
  408.  
  409.  
  410.     Procedure text1.InteractiveChange
  411.         With This
  412.             If (Lastkey() >= 32 And Lastkey() <= 127)
  413.                 .nIDSelStart = Icase(.nIDSelStart >= 0 And Lastkey() = 127,.nIDSelStart - 1,;
  414.                     .nIDSelStart < 0,0,;
  415.                     .nIDSelStart + 1)
  416.                 Select customer
  417.                 coldtag = Tag()
  418.                 Set Order To Tag company
  419.                 Locate For Substr(Alltrim(Upper(customer.company)),1,.nIDSelStart) = ;
  420.                     Upper(Substr(This.Value,1,.nIDSelStart))
  421.                 ***** Could use a SEEK() as well
  422.                 If  Found()
  423.                     This.Value = customer.company
  424.                 Else
  425.                     If !Empty(This.Value)
  426.                         .nIDSelStart = This.SelStart
  427.                     Else
  428.                         .nIDSelStart = 0
  429.                     Endif
  430.                 Endif
  431.                 This.SelStart = .nIDSelStart
  432.                 Set Order To Tag (coldtag)
  433.             Endif
  434.         Endwith
  435.         This.SelLength = Iif(!Empty(This.Value),(Len(Alltrim(This.Value))-(This.nIDSelStart)),1)
  436.     Endproc
  437.  
  438.  
  439.     Procedure text1.Init
  440.         If !Pemstatus(This,"nIDSelStart",5)
  441.             This.AddProperty("nIDSelStart",0)
  442.         Endif
  443.     Endproc
  444.  
  445.  
  446. Enddefine
  447. *
  448. *-- EndDefine: for
  449. *-- BaseClass:    form
  450. *-- Time Stamp:   02/02/07 01:25:12 AM
  451. *
  452. Define Class form1 As Form
  453.  
  454.  
  455.     Top = 3
  456.     Left = 48
  457.     Height = 100
  458.     Width = 375
  459.     DoCreate = .T.
  460.     ShowTips = .T.
  461.     Caption = "Auto Complete"
  462.     Name = "Form1"
  463.  
  464.  
  465.     Add Object command1 As CommandButton With ;
  466.         Top = 67, ;
  467.         Left = 278, ;
  468.         Height = 27, ;
  469.         Width = 84, ;
  470.         Caption = "Close", ;
  471.         TabIndex = 2, ;
  472.         Name = "Command1"
  473.  
  474.  
  475.     Add Object label1 As Label With ;
  476.         AutoSize = .T., ;
  477.         Caption = "Company", ;
  478.         Height = 17, ;
  479.         Left = 60, ;
  480.         Top = 25, ;
  481.         Width = 55, ;
  482.         TabIndex = 3, ;
  483.         Name = "Label1"
  484.  
  485.  
  486.     Add Object text1 As TextBox With ;
  487.         Format = "K", ;
  488.         Height = 23, ;
  489.         Left = 120, ;
  490.         SelectOnEntry = .T., ;
  491.         TabIndex = 1, ;
  492.         Top = 20, ;
  493.         Width = 207, ;
  494.         Name = "Text1"
  495.  
  496.  
  497.     Procedure Load
  498.         If Used("customer")
  499.             Use In customer
  500.         Endif
  501.         **** Do not need to do this if there is an Index
  502.         Set Exclusive On
  503.         ************************************************
  504.         Select 0
  505.         Use Home()+"samples\data\customer.dbf"
  506.         ************************************************
  507.         Index On company Tag company
  508.         Set Order To Tag company
  509.         ************************************************
  510.     Endproc
  511.  
  512.  
  513.     Procedure command1.Click
  514.         Thisform.Release
  515.     Endproc
  516.  
  517.  
  518.     Procedure text1.InteractiveChange
  519.         With This
  520.             If (Lastkey() >= 32 And Lastkey() <= 127)
  521.                 .nIDSelStart = Icase(.nIDSelStart >= 0 And Lastkey() = 127,.nIDSelStart - 1,;
  522.                     .nIDSelStart < 0,0,;
  523.                     .nIDSelStart + 1)
  524.                 Select customer
  525.                 coldtag = Tag()
  526.                 Set Order To Tag company
  527.                 Locate For Substr(Alltrim(Upper(customer.company)),1,.nIDSelStart) = ;
  528.                     Upper(Substr(This.Value,1,.nIDSelStart))
  529.                 ***** Could use a SEEK() as well
  530.                 If  Found()
  531.                     This.Value = customer.company
  532.                 Else
  533.                     If !Empty(This.Value)
  534.                         .nIDSelStart = This.SelStart
  535.                     Else
  536.                         .nIDSelStart = 0
  537.                     Endif
  538.                 Endif
  539.                 This.SelStart = .nIDSelStart
  540.                 Set Order To Tag (coldtag)
  541.             Endif
  542.         Endwith
  543.         This.SelLength = Iif(!Empty(This.Value),(Len(Alltrim(This.Value))-(This.nIDSelStart)),1)
  544.     Endproc
  545.  
  546.  
  547.     Procedure text1.Init
  548.         If !Pemstatus(This,"nIDSelStart",5)
  549.             This.AddProperty("nIDSelStart",0)
  550.         Endif
  551.     Endproc
  552.  
  553.  
  554. Enddefine
  555. *
  556. *-- EndDefine: for
  557. *-- Time Stamp:   02/02/07 01:25:12 AM
  558. *
  559. Define Class form1 As Form
  560.  
  561.  
  562.     Top = 3
  563.     Left = 48
  564.     Height = 100
  565.     Width = 375
  566.     DoCreate = .T.
  567.     ShowTips = .T.
  568.     Caption = "Auto Complete"
  569.     Name = "Form1"
  570.  
  571.  
  572.     Add Object command1 As CommandButton With ;
  573.         Top = 67, ;
  574.         Left = 278, ;
  575.         Height = 27, ;
  576.         Width = 84, ;
  577.         Caption = "Close", ;
  578.         TabIndex = 2, ;
  579.         Name = "Command1"
  580.  
  581.  
  582.     Add Object label1 As Label With ;
  583.         AutoSize = .T., ;
  584.         Caption = "Company", ;
  585.         Height = 17, ;
  586.         Left = 60, ;
  587.         Top = 25, ;
  588.         Width = 55, ;
  589.         TabIndex = 3, ;
  590.         Name = "Label1"
  591.  
  592.  
  593.     Add Object text1 As TextBox With ;
  594.         Format = "K", ;
  595.         Height = 23, ;
  596.         Left = 120, ;
  597.         SelectOnEntry = .T., ;
  598.         TabIndex = 1, ;
  599.         Top = 20, ;
  600.         Width = 207, ;
  601.         Name = "Text1"
  602.  
  603.  
  604.     Procedure Load
  605.         If Used("customer")
  606.             Use In customer
  607.         Endif
  608.         **** Do not need to do this if there is an Index
  609.         Set Exclusive On
  610.         ************************************************
  611.         Select 0
  612.         Use Home()+"samples\data\customer.dbf"
  613.         ************************************************
  614.         Index On company Tag company
  615.         Set Order To Tag company
  616.         ************************************************
  617.     Endproc
  618.  
  619.  
  620.     Procedure command1.Click
  621.         Thisform.Release
  622.     Endproc
  623.  
  624.  
  625.     Procedure text1.InteractiveChange
  626.         With This
  627.             If (Lastkey() >= 32 And Lastkey() <= 127)
  628.                 .nIDSelStart = Icase(.nIDSelStart >= 0 And Lastkey() = 127,.nIDSelStart - 1,;
  629.                     .nIDSelStart < 0,0,;
  630.                     .nIDSelStart + 1)
  631.                 Select customer
  632.                 coldtag = Tag()
  633.                 Set Order To Tag company
  634.                 Locate For Substr(Alltrim(Upper(customer.company)),1,.nIDSelStart) = ;
  635.                     Upper(Substr(This.Value,1,.nIDSelStart))
  636.                 ***** Could use a SEEK() as well
  637.                 If  Found()
  638.                     This.Value = customer.company
  639.                 Else
  640.                     If !Empty(This.Value)
  641.                         .nIDSelStart = This.SelStart
  642.                     Else
  643.                         .nIDSelStart = 0
  644.                     Endif
  645.                 Endif
  646.                 This.SelStart = .nIDSelStart
  647.                 Set Order To Tag (coldtag)
  648.             Endif
  649.         Endwith
  650.         This.SelLength = Iif(!Empty(This.Value),(Len(Alltrim(This.Value))-(This.nIDSelStart)),1)
  651.     Endproc
  652.  
  653.  
  654.     Procedure text1.Init
  655.         If !Pemstatus(This,"nIDSelStart",5)
  656.             This.AddProperty("nIDSelStart",0)
  657.         Endif
  658.     Endproc
  659.  
  660.  
  661. Enddefine
  662. *
  663. *-- EndDefine: for
  664. *
  665. Define Class form1 As Form
  666.  
  667.  
  668.     Top = 3
  669.     Left = 48
  670.     Height = 100
  671.     Width = 375
  672.     DoCreate = .T.
  673.     ShowTips = .T.
  674.     Caption = "Auto Complete"
  675.     Name = "Form1"
  676.  
  677.  
  678.     Add Object command1 As CommandButton With ;
  679.         Top = 67, ;
  680.         Left = 278, ;
  681.         Height = 27, ;
  682.         Width = 84, ;
  683.         Caption = "Close", ;
  684.         TabIndex = 2, ;
  685.         Name = "Command1"
  686.  
  687.  
  688.     Add Object label1 As Label With ;
  689.         AutoSize = .T., ;
  690.         Caption = "Company", ;
  691.         Height = 17, ;
  692.         Left = 60, ;
  693.         Top = 25, ;
  694.         Width = 55, ;
  695.         TabIndex = 3, ;
  696.         Name = "Label1"
  697.  
  698.  
  699.     Add Object text1 As TextBox With ;
  700.         Format = "K", ;
  701.         Height = 23, ;
  702.         Left = 120, ;
  703.         SelectOnEntry = .T., ;
  704.         TabIndex = 1, ;
  705.         Top = 20, ;
  706.         Width = 207, ;
  707.         Name = "Text1"
  708.  
  709.  
  710.     Procedure Load
  711.         If Used("customer")
  712.             Use In customer
  713.         Endif
  714.         **** Do not need to do this if there is an Index
  715.         Set Exclusive On
  716.         ************************************************
  717.         Select 0
  718.         Use Home()+"samples\data\customer.dbf"
  719.         ************************************************
  720.         Index On company Tag company
  721.         Set Order To Tag company
  722.         ************************************************
  723.     Endproc
  724.  
  725.  
  726.     Procedure command1.Click
  727.         Thisform.Release
  728.     Endproc
  729.  
  730.  
  731.     Procedure text1.InteractiveChange
  732.         With This
  733.             If (Lastkey() >= 32 And Lastkey() <= 127)
  734.                 .nIDSelStart = Icase(.nIDSelStart >= 0 And Lastkey() = 127,.nIDSelStart - 1,;
  735.                     .nIDSelStart < 0,0,;
  736.                     .nIDSelStart + 1)
  737.                 Select customer
  738.                 coldtag = Tag()
  739.                 Set Order To Tag company
  740.                 Locate For Substr(Alltrim(Upper(customer.company)),1,.nIDSelStart) = ;
  741.                     Upper(Substr(This.Value,1,.nIDSelStart))
  742.                 ***** Could use a SEEK() as well
  743.                 If  Found()
  744.                     This.Value = customer.company
  745.                 Else
  746.                     If !Empty(This.Value)
  747.                         .nIDSelStart = This.SelStart
  748.                     Else
  749.                         .nIDSelStart = 0
  750.                     Endif
  751.                 Endif
  752.                 This.SelStart = .nIDSelStart
  753.                 Set Order To Tag (coldtag)
  754.             Endif
  755.         Endwith
  756.         This.SelLength = Iif(!Empty(This.Value),(Len(Alltrim(This.Value))-(This.nIDSelStart)),1)
  757.     Endproc
  758.  
  759.  
  760.     Procedure text1.Init
  761.         If !Pemstatus(This,"nIDSelStart",5)
  762.             This.AddProperty("nIDSelStart",0)
  763.         Endif
  764.     Endproc
  765.  
  766.  
  767. Enddefine
  768. *
  769. *-- EndDefine: for
  770. *
  771. *-- EndDefine: for
  772. *-- EndDefine: form1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement