Code for Draw Program

I am learnig VB6 and i am looking for a source code to draw lines,circles, and freehand form.

Thanks,

Jairo
jcardenasAsked:
Who is Participating?
 
ArkConnect With a Mentor Commented:
Hi
There are a lot of links about drawings at the Web. Next two:
http://www.codearchive.com/vbasic//paint.zip
http://www.codearchive.com/vbasic//drawdemo.zip

IMHO, you have enough to choose :-)
Cheers
0
 
RuchiCommented:
this is a sample example -- form. try to use this following code. this is to basically scribble-draw with your mouse.

Option Explicit

Private Sub Form_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
    frmDraw.CurrentX = X
    frmDraw.CurrentY = Y

End Sub

Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)

 If Button = 1 Then
   Line (frmDraw.CurrentX, frmDraw.CurrentY)-(X, Y), QBColor(0)
 End If

End Sub
0
 
CrinCommented:
Hello Jairo,

just type "Line" in the code module and press F1, in most cases help files covers needs of learning...

Repeat this with word "Circle".

Sincerely yours,

Crin
0
Cloud Class® Course: Microsoft Office 2010

This course will introduce you to the interfaces and features of Microsoft Office 2010 Word, Excel, PowerPoint, Outlook, and Access. You will learn about the features that are shared between all products in the Office suite, as well as the new features that are product specific.

 
AzraSoundCommented:
http://www.codearchive.com/vbasic/graphics.html

lots of drawing examples there for you to look through
0
 
ArkCommented:
<Make a simple drawing program that demonstrates a lot of useful techniques (32K)>
http://www.vb-helper.com/Howto/compat.zip
Cheers
0
 
jcardenasAuthor Commented:
Ok,thanks for your excellent help, with the codes submmited by Ark and Ruchi is clear the functions for Line, Circle; but for freehand is not, can you give some help about.

Thanks,

Jairo
Colombia
0
 
AzraSoundCommented:
i know one of those samples at the link i pointed to demomstrates that
0
 
RuchiCommented:
0
 
RuchiCommented:
It's about free hand pencil drawing. Very good information
http://www.activex3d.com/Items/LearnVisualBasicFast/Learn_Visual_Basic_Fast_022.htm
0
 
ArkCommented:
Hi
Interesting sample:
http://www.freevbcode.com/ShowCode.Asp?ID=964
Cheers
0
 
adam8Commented:
The following code sample won a contest for best code.
I recommend you try it..

http://www.planet-source-code.com/vb/scripts/ShowCode.asp?lngWId=1&txtCodeId=2801

0
 
jcardenasAuthor Commented:
Thanks for your Support,


Regards,

Jairo
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.