473,396 Members | 2,011 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Drawing Simple Graph in VB

Hi,

I have a user entering information into a MSFlexGrid and want to graph some of the data using a line graph. I tried using MSChart but it doesn't seem to work for me. Does anyone have any other suggestions?

Thanks in advance.
May 14 '07 #1
5 4603
Killer42
8,435 Expert 8TB
I have a user entering information into a MSFlexGrid and want to graph some of the data using a line graph. I tried using MSChart but it doesn't seem to work for me. Does anyone have any other suggestions?
You could draw it yourself. For that matter, you could create a user control which draws a chart the way you want.

By the way, what version of VB are you using?

Also, if you describe what you don't like about MSChart, there may be someone who knows a way around the problem.
May 15 '07 #2
You could draw it yourself. For that matter, you could create a user control which draws a chart the way you want.

By the way, what version of VB are you using?

Also, if you describe what you don't like about MSChart, there may be someone who knows a way around the problem.
I am using VB6. The problem I had with MSChart was that I wasn't able to find a way to assign the data from my MSFlexGrid to the MSChart.

Right now I am using a picture box and the Line function to create a graph but the problem I am having with that is that I can't seem to give the graph an axis and the graph doesn't look too pretty.

If someone could help me out that would be great. Thanks!!
May 15 '07 #3
Killer42
8,435 Expert 8TB
I am using VB6. The problem I had with MSChart was that I wasn't able to find a way to assign the data from my MSFlexGrid to the MSChart.

Right now I am using a picture box and the Line function to create a graph but the problem I am having with that is that I can't seem to give the graph an axis and the graph doesn't look too pretty.

If someone could help me out that would be great. Thanks!!
Hm... can you explain in more detail what you mean by "can't seem to give the graph an axis"? (I'll take a stab in the dark and say that you need to turn AutoRedraw on before drawing your axis, and off again afterward. But that's just guesswork, of course.)

As for MSChart, you might do well to try the search box up the top of the page. The MSChart control has been discussed here quite a few times, so you may find what you need is already here.
May 15 '07 #4
Hm... can you explain in more detail what you mean by "can't seem to give the graph an axis"? (I'll take a stab in the dark and say that you need to turn AutoRedraw on before drawing your axis, and off again afterward. But that's just guesswork, of course.)

As for MSChart, you might do well to try the search box up the top of the page. The MSChart control has been discussed here quite a few times, so you may find what you need is already here.
Hi,

The problem with the axis is that when i draw a line graph nothing on the axis shows up. So if my y axis is from 0 to 1 i want that to show up but it doesn't.

I've also checked the other inquires about MSChart but nothing really seems to help me out. Mostly everything I have seen online has MSChart working with a database or datagrid but not a flexgrid, any ideas?
May 17 '07 #5
Killer42
8,435 Expert 8TB
I finally figured out how to use MSChart, one thing I was wondering was whether it is possible to have an x y and z axis using this chart?
I don't know. I'd suggest you post that as a new question, here in the VB forum, for a better response.

A lot of people watch for questions with no replies, so won't notice a thread which has gone on for a while like this one.

In fact, I'll do it for you. Here, I've split off that message to this thread.
May 18 '07 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

6
by: TheDD | last post by:
Hi all, i have a question: is there any librairy for drawing graphs with PHP? Not graphs like histogram or alike, but like a set of shapes linked together in a certain way (like a flow chart...
8
by: Stefan Burger | last post by:
Those of you who are in need for drawing vector lines might be interested in the following code. DrawLine( x1, y1, x2, y2, color ) draws a vector line from any Point x1,y1 to any Point x2,y2 in...
0
by: SS KANAGAL | last post by:
Hello, I am drawing a bar graph in an aspx page using System.Drawing namespace . Now I want to provide drill down facility for the graph i.e. on click of a bar in the graph it should get me yet...
0
by: SS KANAGAL | last post by:
Hello, I am drawing a bar graph in an aspx page using System.Drawing namespace . Now I want to provide drill down facility for the graph i.e. on click of a bar in the graph it should get me yet...
1
by: DBC User | last post by:
Hi Sharpies, This is a very basic question. I am using .Net IDE 2003 and System.Drawing.dll (1.1.4322). I wrote a simple program like this (ommitting the commons) using System.Drawing; .....
1
by: anthonyroche | last post by:
Does anyone know of a product that allows a user to draw a line on a chart? eg A historical stock tracker would have a line graph of say Aug 03 to Dec 03, which is a line graph representing a...
2
by: ys | last post by:
Good day.Currently I am doing Knowledge Base Planner. I do wish to show a result of my plan on the interface. What should i read in Graphics / Drawing to display my result by showing a straight...
1
by: RichMo | last post by:
Hi, I'm new to C++ and i can't seem to find a tutorial on the net for this one. I have a dialog based MFC app running that reads sensors using a USB interface device. At the moment the...
9
by: davetelling | last post by:
I am not a programmer, I'm an engineer trying to make an interface to a product I'm designing. I have used C# to make a form that interrogates the unit via the serial port and receives the data. I...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.