Solved

Lines in VB6

Posted on 2000-03-21
2
137 Views
Last Modified: 2010-05-02
Is it difficult to Draw a line on the canvas, then by clicking close to one end with the mouse, pick another point on the canvas and by clicking the mouse again to remove the old line and create the new one, while maintaining the lines other end ?

Also is it possible to have a tool tip when passing the mouse over a line ?
0
Comment
Question by:carmis
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 

Accepted Solution

by:
justinflitcroft earned 30 total points
ID: 2643098
It's not very difficult to do, but there a number of ways of doing it.
To make it draw a line between 2 mouse clicks, write code that saves the coordinates of the first click, waits for the 2nd click and saves its coordinates, then draws a line from these 2 coordinates. There are a number of ways of determining whether the click is the 1st or 2nd, including storing it in a variable.

As for the tooltip, you can use API functions to display tooltips, but you would have to write code to determine if the mouse was currently over the line or not.
0
 

Author Comment

by:carmis
ID: 2643184
I am trying to draw a line, then by clicking near one end of the same line to choose it, an then to revise the location of the new end, I would like to draw a line for Example at 45 degrees, then pick and drag that end over and down to 30 degrees, removing the one that was drawn at 45.

Hey thanks Carm
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction I needed to skip over some file processing within a For...Next loop in some old production code and wished that VB (classic) had a statement that would drop down to the end of the current iteration, bypassing the statements that were c…
The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question