2 Question (Even 1 will help a lot):
(1) How can I display the real time data (which my methods return in a C# console application) in the ASP GridView?
(2) Once the data is displayed in the GridView, how can I draw a plot of that data and display in ASP?
Detail of my project:
Guys, I am working on a C# console application and am stuck on the above 2 questions. I will really appreciate some help asap.
The data is sitting in the MS Access database which is updated daily. I have methods that return objects of data. The main class code looks like this:
using System;
using System.Collections.Generic;
using System.Text;
using MuniDataAccess.Yields;
namespace MuniDataAccess
{
class Program
{
static void
{
DateTime dt = new DateTime(2007, 6, 13);
int tm = 30;
YieldData yld = new YieldData();
Console.WriteLine("Getting data for " + tm.ToString() + "; " + dt.ToShortDateString());
Console.WriteLine("The MMD yield is: " + yld.GetAaaMMD(dt, tm));
Console.WriteLine("The Tsy yield is: " + yld.GetAaaTsy(dt, tm));
Console.WriteLine("The Libor Yield is:" + yld.GetAaaLibor(dt, tm));
Console.WriteLine("The BMA Yield is:" + yld.GetAaaBMA(dt, tm));
SortedList<int, MMDYield> lst = yld.GetMMDAll(dt);
for (int i=0; i < lst.Count; i++)
{
MMDYield y = lst.Values[i];
Console.WriteLine("The " + y.Term.ToString("0")
+ "yr MMD yield is: " + y.Aaa.ToString("0.00"));
}
Console.Read();
}
}
}
Mike GoldPosted Jun 15, 2007, 1:57 AM
<form id="Form1" method="post" runat="server"> <asp:table id="Table1" style="Z-INDEX: 101; LEFT: 26px; POSITION: absolute; TOP: 27px" runat="server" Width="550px" Height="310px" CellSpacing="1" CellPadding="1">asp:table> <asp:AccessDataSource ID="AccessDataSource1" runat="server" DataFile="~/Quiz.mdb" DataSourceMode="DataSet" SelectCommand="SELECT * FROM [Choices]">asp:AccessDataSource> form>
2) You may need to get a third party solution for graphing in ASP.NET such as the Dundas Library.