Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. file info. rss.
 From: Gerrit Broekhuis
  Where is Gerrit Broekhuis?
 holten
 Netherlands
 Gerrit Broekhuis
 To: Mike Yearwood
  Where is Mike Yearwood?
 Toronto
 Canada
 Mike Yearwood
 Tags
Subject: RE: Select a single word in a string
Thread ID: 434203 Message ID: 434221 # Views: 38 # Ratings: 0
Version: Visual FoxPro 9 SP2 Category: Forms
Date: Wednesday, February 24, 2016 8:46:45 AM         
   


> >
> > Hi Greg,
> >
> > I know how to break the string into seperate words and already have a routine tor that. I have to show the full sentence and then click / select as single word (by mouseclick).
> > For each sentence I allow selecting only one word.
> >
> > The selected word should (in this case) be the most important word of the sentence, the subject or main theme.
> >
> > Regards, Gerrit
>
> If the sentence is in a textbox, you can use textbox.seltext to determine what the user selected. See also selstart for the position, and sellength for the length of the selection.
>
> Mike Yearwood
> Microsoft MVP Visual FoxPro 2008, 2009
> We have enough youth. We need a fountain of smart!
> There may be many ways to skin a cat, but there are very few right ways to do it.
> You can't teach an old dog new tricks. Heaven forbid I become a dog or old.

Hi Mike,

I need to select with just a single mouse click (if possible). Textbox.seltext is not doing that I think.

I 'm thinking now to put all words from this string in a cursor and use a single row grid with invisible lines for selection. Columnwidth should be made te just fit each word, to make it look like there is no grid at all.

Regards, Gerrit

ENTIRE THREAD

Select a single word in a string Posted by Gerrit Broekhuis @ 2/23/2016 8:24:04 PM
RE: Select a single word in a string Posted by António Lopes @ 2/23/2016 8:48:05 PM
RE: Select a single word in a string Posted by Gerrit Broekhuis @ 2/23/2016 9:19:45 PM
RE: Select a single word in a string Posted by Greg Green @ 2/23/2016 9:10:55 PM
RE: Select a single word in a string Posted by Gerrit Broekhuis @ 2/23/2016 9:19:09 PM
RE: Select a single word in a string Posted by Mike Yearwood @ 2/23/2016 10:33:54 PM
RE: Select a single word in a string Posted by Gerrit Broekhuis @ 2/24/2016 8:46:45 AM
RE: Select a single word in a string Posted by Fernando Bozzo @ 2/24/2016 10:11:53 AM
RE: Select a single word in a string Posted by Gerrit Broekhuis @ 2/24/2016 11:10:55 AM
RE: Select a single word in a string Posted by Mike Yearwood @ 2/24/2016 3:11:48 PM
RE: Select a single word in a string Posted by Gerrit Broekhuis @ 2/24/2016 7:56:16 PM