Adding Graphs to Forms

042355C

Active member
Joined
Nov 30, 2006
Messages
30
Programming Experience
Beginner
Hi to all,

I am doing a windows application programme on Health using vb.net 2003. Right now, my task is to create a graph to display the number of people within a range of blood pressure. The number of people is in my database(ODBC).

I really really need help in this. All the websites I visit needs me to enter the exact value, which means I will have to change when the number in database changes.

Is there anyway to create a graph whereby it will correspond according the the database?

Thanks a million!
 
Last edited:
when you are creating a reporting project, you specify the select query when you are setting up the report - so whether or not you have anything in the textboxes is irrelevant (unless you want to use something in the textboxes, as say a parameter to further refine the query you can define custom parameters and supply them through the url.)..

are you able to get access/install sql server reporting services 2005?

does anyone else that reads this know if srs2005 will work with an sql server 2000 db? as well as that, it work with vs.net2003?

its been a while since ive touched a vs.net2003 app what im suggesting might not be possible because of the limitations of what you have to work with. maybe you could persuade your teacher to install vbexpress 2005? its free, as is sql server 2005 express and sql server reporting services 2005.

maybe someone else who has had experience with srs 2000 can help you a bit more, but im afraid ive probably reached the limit of how much i can help you. i have no idea if the process for reporting is the same in 2000 as it is in 2005.

good luck!
 
also, i would further investigate jmc's idea of using the third party graphing controls... about 99% of the work would be done for you, all you need to do is figure out how and where to implement it in your application, then simply grab say a dataset, and use that as a datasource to populate the graph information. takes away the screwing around of getting srs2k5 to work as well
 
I really don't get this. I can't think why you would be hassling with browser controls, etc. when there are components specifically created for charting. Seems like you're just making it harder to me.
 
jmc, thats basically what i just said. i acknowledged the fact that your way would be easier.


anyway, the reason someone might want to do it like that, is so that the reports can be viewed from anywhere, not just from within the application.

it might be a bit harder at the start, but it ensures that a wide range of people can view the information that they need to later, as long as they have the internet. thats why i suggested my way.
 
jmc, thats basically what i just said. i acknowledged the fact that your way would be easier.


anyway, the reason someone might want to do it like that, is so that the reports can be viewed from anywhere, not just from within the application.

it might be a bit harder at the start, but it ensures that a wide range of people can view the information that they need to later, as long as they have the internet. thats why i suggested my way.
There's nothing in this thread that indicates that that is necessary or desirable. It's been stated that this is a Windows app and the aim is to display a chart on a Windows form. We could do lots of things in Web browsers for the portability but if there is no reasonable expectation that that portability will be required then trying to provide is probably going to be a liability. If you can use a WinForms component that let's you specify a few properties and then pass some data and it does the rest then that is the obvious way to proceed in my opinion.

By the way, I didn't specifically read post #19. I just noticed that this thread was going on and on in a direction that I don't consider optimal so I posted. A reasonable level of competence with NPlot or ZedGraph could have been acquired by now. My comment was more a criticism of the OP for not taking what I consider to be the obvious route. Trying to kludge a workaround when a specific solution exists is counter-productive in my opinion. The only reasonable alternative that I see is to draw it yourself using GDI+, but only if you either want to control the drawing yourself or to learn about GDI+.
 
A reasonable level of competence with NPlot or ZedGraph could have been acquired by now.
But it is only for vb.net 2005, I am told to use only vb.net 2003. It is not that I do not want to use NPlot or ZedGraph, but it is only compatible for vb.net 2005, therefore I cannot use. :( Furthermore, I cannot get an 'older' version of NPlot, therefore it won't work on vb.net 2003, right?

My comment was more a criticism of the OP for not taking what I consider to be the obvious route. Trying to kludge a workaround when a specific solution exists is counter-productive in my opinion.
Perhaps that is because it cannot work on vb.net 2003?
 
*sigh*
Note that the newest versions of both those components are for .NET 2.0 I believe. You'll need to download a slightly older version to get .NET 1.1 support.
ZedGraph supported .NET 1.1 up to version 4.3.5, which you can access from the download page by clicking the "older releases" link. The NPlot download page specifically states that the package contains binaries for .NET 1.1 and 2.0.
 
*sigh*ZedGraph supported .NET 1.1 up to version 4.3.5, which you can access from the download page by clicking the "older releases" link. The NPlot download page specifically states that the package contains binaries for .NET 1.1 and 2.0.

when i try to open, it says it is a file of a newer version, therefore unable to open. Can this problem be solved other than to change to .net 2.0?
 
maybe your school needs to update their vs.net 2003?

just a thought.

jmc, lay off the poor guy, will ya? the "*sigh*" in your post was unnecessary. im not trying to start on you or anything, but maybe you should be a bit more understanding if your gonna post to someone who obviously lacks the knowledge you do. even if he didnt read the site properly, people make mistakes
 
Last edited:
I just downloaded ZedGraph 4.3.5 and NPlot 0.9.10.0. I extracted the two ZIP files. I opened VS.NET 2003 and created a project. I then successfully added references to zedgraph_dll_4.3.5\ZedGraph.dll and nplot-0.9.10.0\bin\net\1.1\release\NPlot.dll. That proves that they both work exactly as they should. If you're downloading the wrong version of ZedGraph or referencing NPlot from the wrong folder then they won't work. Straightforward?
 
ok, I made reference already. I have got 5 different values to be displayed. the values are displayed in the textbox. Can I know how to get the value to be used in nPlot?
 
Never used it, but the extracted archive creates folders for documentation and demos. The NPlot Web site also has a small VB tutorial. Zedgraph also provides a C# tutorial and VB samples.
 
The NPlot Web site also has a small VB tutorial.
NPlot can only make line graph. I need histogram.(all thanks to my teacher, requesting such thing...)
Zedgraph also provides a C# tutorial and VB samples.
but it never says how to get information from textbox, or even from database...
 
Last edited:
i think what you need to find out is what sort of datasource the graph control will accept, if it is a dataset or some such thing its as simple as retrieving the data, putting it into a dataset and databinding it.

of course, i cant be sure about this because like jmc i havent used it before, im just going on what i know (or not know :p)

lol... teachers (*starts thinking about back in the day). think about it this way, what he is asking might be hard to implement, but if you do it you will have that hard earned knowledge for the rest of your life, and you will be able to adapt it to different situations.

have a good one mate, and good luck
regards
adam
 
Back
Top