473,396 Members | 2,016 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.

Graphing data in VB.net - What is the fastest and easiest way?

What is the fastest and easiest way to graph data in VB.net?

How do I export 2 columns of data in Vb.net, to either an excel file or to a notepad file?
Sep 15 '09 #1
8 3747
tlhintoq
3,525 Expert 2GB
How do I export 2 columns of data in Vb.net, to either an excel file or to a notepad file?
I guess that all depends on what your "columns" really consist of in code.
Do you have a two dimensional string array? string[10, 20]
Do you have a dictionary? Dictionary<int, string>

Loop through whatever variable list/array you have and write the values to a text file. You might want to go to MSDN and read up on the Streamwriter.
http://msdn.microsoft.com/en-us/library/6ka1wd3w.aspx
Sep 15 '09 #2
tlhintoq
3,525 Expert 2GB
What is the fastest and easiest way to graph data in VB.net?
Read up on MSDN regarding the Drawing class.
http://msdn.microsoft.com/en-us/library/bb196414.aspx
Sep 15 '09 #3
The data is in the form of a two dimensional string array.
Sep 15 '09 #4
tlhintoq
3,525 Expert 2GB
@petesquawk
Then my original suggestion holds up well.
Loop through whatever variable list/array you have and write the values to a text file. You might want to go to MSDN and read up on the Streamwriter.
http://msdn.microsoft.com/en-us/library/6ka1wd3w.aspx
If you comma-separate or tab-separate the two fields it will import to Excel easily.
Sep 15 '09 #5
I guess that all depends on what your "columns" really consist of in code.
Do you have a two dimensional string array? string[10, 20]
Do you have a dictionary? Dictionary<int, string>

Loop through whatever variable list/array you have and write the values to a text file. You might want to go to MSDN and read up on the Streamwriter.
http://msdn.microsoft.com/en-us/library/6ka1wd3w.aspx
I haven't gotten to the graphing portion yet, but the first VB example on http://msdn.microsoft.com/en-us/library/6ka1wd3w.aspx works very well. Thank you.
Sep 16 '09 #6
Read up on MSDN regarding the Drawing class.
http://msdn.microsoft.com/en-us/library/bb196414.aspx
I don't know how to implement that code for vb.

I have been able to get a ZedGraph application working by itself but I haven't been able to get it to work with my code yet. I tried installing MS Chart control but I was unable to get that to work, even after upgrading to SP1 for 3.5.

I am thinking that I might be able to get ZedGraph to work if I put more time into it.
Sep 16 '09 #7
tlhintoq
3,525 Expert 2GB
Take a look around the rest of the MSDN. There is LOTS of documentation.
Take a look at the drawing namespace
http://msdn.microsoft.com/en-us/libr...m.drawing.aspx

Here's a tip: Google for the terms "MSDN System.Drawing"
Basically if you Google "MSDN" plus whatever it is you are looking for you will get all the MSDN hits related to what you are working on.
From there... "Right-Click | Open in new tab" in your browser until you find something useful. I find this great for keeping the Google reply as a table of contents and several MSDN articles open at once
Sep 16 '09 #8
I was able to get Zedgraph to work. I just needed to add under the Solution folder and Zedgraph.dll under the reference section.
Sep 18 '09 #9

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

Similar topics

3
by: Kova | last post by:
Hello. As I just started, I wan't to know what's the best (fastest, easiest, whatever just best) way to deal with instances of objects when creating them. For example I use JFileChooser more times...
6
by: Michael Hill | last post by:
Hello, all. I am considering writing an online graphing utility. I plan it to be of good quality, such that an undergraduate university student can print it out and include it with a lab report....
11
by: DraguVaso | last post by:
Hi, I should use XML to synchronize the data from different (VB.NET) applications, and I was just wondering which Overloads of these functions ( ReadXmlSchema, ReadXml and WriteXml) goes the...
16
by: chudson007 | last post by:
I have a table, TableA with amongst other fields, a field for Qty. Qty can range from 0 to 100. How do I count the number of rows with a qty between 1 and 10, 11 and 20, 21 and 30, and so on using...
5
by: David Sagenaut | last post by:
If I have two pages, page1 and page2. In page1, I have a label control. After first request for page1, the label control fills with a text, say "myName", then I pup up the page2. How can I get...
2
by: Brad Markisohn | last post by:
I need to graphically display data retrieved from a device connected to the serial port. Is there a way to do this in .Net or do I need to purchase a 3rd party tool? Thanks Brad
1
by: Craig Buchanan | last post by:
what is the fastest way to remove a value from a string array? something like: dim x as string() = {"A","B","C","D"} 'remove C x.Clear(x, x.IndexOf(x, "C"), 1) Questions:
4
by: Lucvdv | last post by:
What's the fastest/easiest/best way to determine if a certain item exists in a list? (And what's the slowest/dumbest - I suppose that's enumerating the elements and comparing each in turn in VB...
0
by: mjsterz | last post by:
I've been working with VB .NET for less than a year and this is the first time I've posted on one of these groups, so let me apologize beforehand if I'm being unclear, not posting my issue...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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: 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
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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
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...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.