Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Drawing library for VFP
Message
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Miscellaneous
Thread ID:
00829167
Message ID:
00830050
Views:
20
Don,

Thanks for the suggestion. I'll have to check to see if ActiveX controls built in Visual Studio .NET will work easily in VFP 8. If not, I could use VB6.

---Thomas

>Thomas,
>
>I had a very similar situation last year and ended up writing an ActiveX control in VB 6 and dropping it directly onto a VFP form. It has drag and drop icons, a drawing pen, Undo, etc. It is now used very successfully in a nationally sold Dental program. I would do it the same again today if I had to use it in VFP and if it was truly a simple control.
>
>However, in my control users can drop the icon anywhere on the background image. You might need to write some extensive code in the DragDrop event of the background control to track where they are dropping it, so that you can align it to your "Grid". If it gets too complex you will need to use automation as mentioned by others.
>
>In VB6 you create a new ActiveX project, build it, and drop it directly on your VFP form. Very nice, very workable, very stable.
>
>I also write programs in VB.Net, but it could not create ActiveX controls like this for VFP. I tracked down VB 6 samples and source code for this on the Internet without a lot of trouble, and you can too.
>
>Don Meuse
>Spectrum Software
>
>>Martin,
>>
>>This may indeed be the way for me to go, if I cannot expect my users to have Visio.
>>
>>Gratias por su ayuda.
>>
>>---TL
>>
>>>Hi, Thomas.
>>>
>>>>I need to add limited drawing functionality to a VFP application. Specifically, the program will display a grid in a window with a palette of custom icons. Users will drag an icon from the palette and drop it on the grid. There will also be different connectors which users may choose and drag from one icon to another, leaving a line between the two icons. So basically the users are building a graph (in the mathematical sense) with nodes and connections. I also need the ability to display labels next to the nodes and connectors, to print the drawing, save it in the VFP database, recall it and edit it. Certain calculations depend on which icons are on the graph and how they are connected.
>>>>
>>>>There are lots of applications that work like this visually. (E.g. Database design tool in Visual Server .NET) Is there a class library, ActiveX control or other tool for doing this in VFP? Or is there an application that VFP could control via automation that would serve? (I expect I'll have to port this to .NET at a later date.)
>>>
>>>Maybe you can write it in .NET right away and call it from your VFP app. If you want to take this route, take a look at this article:
>>>http://www.code-magazine.com/Article.aspx?quickid=0305061
>>>
>>>I think this pretty much cover what you're trying to do.
>>>
>>>Hope this helps,
Thomas M. Lamm
Bradbury & Associates
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform