Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Use the VFP Intellisense in my Application

Status
Not open for further replies.

Irwin1985

Programmer
Feb 2, 2017
44
0
0
ES
Hi everybody,

Is it possible to use the intellisense in my application...? My users write code in an EditBox control but they don't have the intellisense's advantage. Is there any example or solution for implementiong this idea? I just want to use either the intellisense or the syntax highlight.

Thanks...!
 
Yes, this is possible - but only in a limited way. Basically only in memo fields, and only when edited in the memo field editor.

Doug Hennig has written an article about this, with a lot of detail and examples. See:
But there are also many other ways of providing similar functionality, other than via Intellisense. If that interests you, I can provide some suggestions - as no doubt can others here.

Mike

__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro articles, tips and downloads
 
Thanks Mike, please tell me about it.

I'm going to take a look of Doug's article.
 
Well, this is one approach I took in an application which I developed quite a few years ago. (At the time, I wrote an article about it for Foxpro Advisor, but unfortunately I no longer have a copy, so the following is from memory.)

In my base EditBox class, I had code in the right-click event to pop up a context menu. In addition to the usual context menu options, such as Cut, Copy, Paste, Select All, etc., I had nine entries to correspond to nine standard phrases that were relevant to the user's business. These were things like "We have not yet received payment for our invoice ...", as well as the user's name, the company or department name, today's date, etc.

There was also a tenth item, that led to a cascading set of sub-menus, with many more phrases, categorised by function. For example, there was a menu of phrases relating to sales, another for credit control, and so forth. In this way, it was possible to store around a hundred phrases in a fairly compact menu structure.

The final element was a form in which the user could maintain these phrases. We provided a company-wide phrase book with the application, but individual users could add, delete or alter phrases as they liked. It would have been quite easy to let this phrase book be shared among all users, but we chose not to do that.

This approach was easy to program, and it was popular with most users, although others users disliked it. I think the ones who disliked it were mostly touch-typists, who didn't like to have to take their hands off the keyboard to reach for the mouse to access the menus (we pointed out that they could hit Shift+F10 to bring up the context menu, and then the arrow keys to make their choice, but that wasn't very popular either).

Anyway, that was the approach I took. It's not as slick as Intellisense, but it serves a similar purpose. I'm sure it would be possible to find other solutions, including some that don't require you to take your hands off the keyboard.

Mike


__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro articles, tips and downloads
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top