|
-
Oct 29th, 2000, 03:43 AM
#1
Thread Starter
New Member
hey... can anyone tell me how to make a program that can draw a graph using vb? i am doing a program that is supposed to calculated datas base on an equation and then show the results on a graph. something like an experiment.
thanx anyway.
-
Oct 29th, 2000, 04:31 AM
#2
Frenzied Member
sorry to jump into your post but I've toyed with that idea myself. Well, I got bored with it before I got frustrated.
Anyway, follow this link for a good idea of how to get started.
http://www.planetsourcecode.com/xq/A...s/ShowCode.htm
good luck
Wen Gang, Programmer
VB6, QB, HTML, ASP, VBScript, Visual C++, Java
-
Oct 29th, 2000, 10:05 AM
#3
the MS Chart control does graphs almost exclusively.
-
Oct 29th, 2000, 11:08 AM
#4
Fanatic Member
OLE
Hi you can draw a graph with Excel using an OLE control.
You will need to place an OLE on your form then link it to an Excel chart. Go into the chart and define the blank cells that the chart will be drawn on - just like in Excell.
then define the variables
Set graf = Me![OLE1].object.Charts("Chart1")
Set shet = Me![OLE1].object.Sheets("Sheet1")
To setup the OLE:
With OLE2
.Format = "CF_TEXT"
.SizeMode = vbOLESizeStretch
End With
To define the chart type:
graf.ChartType = xlXYScatterLines
To define the title and label of axes
graf.ChartWizard _
Title:="TITLE OF GRAPH", HasLegend:=False, CategoryTitle:="X AXIS", ValueTitle:="Y AXIS"
To set a value:
she.Cells(X, Y).Value = VALUE
For more information see excel macro help.
-
Oct 29th, 2000, 10:27 PM
#5
Thread Starter
New Member
hey.. thanx anyway..
this is my first time i am using this msg thing..
never expect it to have so much reply!!!
i am overwhelm!
thanx!!!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|