|
You can learn by reading a few books on C#.
There will be a number of samples that you could try from these books.
|
|
|
|
|
Thank you sir Abhinav S it can help me a lot ....
|
|
|
|
|
You need just practice and practice and practice to improve your skills in this level.
/* LIFE RUNS ON CODE */
|
|
|
|
|
what is encapsulation with c# coding exnmple
|
|
|
|
|
|
I have created a windows form chart and it is very small the only way I can change its size is by stretching the chart but it is only a percentage of the charts container size, I have spent forever going through the properties and I cannot see what is affecting it, here is an image of it:
http://deucalion0.co.uk/chart.PNG[^]
You can see the white are is the size of the chart but it is nowhere near the same size, can anyone tell me why?
Thank you!!
|
|
|
|
|
Without knowing what you're using for a chart control or if you made your own, it's pretty much impossible to help you.
|
|
|
|
|
I apologise for the lack of information in my question!
I am using this:
using System.Windows.Forms.DataVisualization.Charting;
The code for my chart properties in the designer file is as follows:
chartArea1.Name = "ChartArea1";
this.chart1.ChartAreas.Add(chartArea1);
legend1.Name = "Legend1";
this.chart1.Legends.Add(legend1);
this.chart1.Location = new System.Drawing.Point(0, 0);
this.chart1.Name = "chart1";
series1.ChartArea = "ChartArea1";
series1.Legend = "Legend1";
series1.Name = "Plots";
series2.ChartArea = "ChartArea1";
series2.Legend = "Legend1";
series2.Name = "Regression Line";
this.chart1.Series.Add(series1);
this.chart1.Series.Add(series2);
this.chart1.Size = new System.Drawing.Size(1212, 771);
this.chart1.TabIndex = 13;
this.chart1.Text = "chart1";
this.chart1.Click += new System.EventHandler(this.chart1_Click);
I am new to this kind of project So forgive me if there is still something missing.
Thank you!
|
|
|
|
|
The code isn't here, but you may have set the size of the ChartArea1 in the designer to be a fixed size instead of Auto.
I preffer to remove all of the default collection items that dropping the chart object on the form adds, including all Legends, ChartAreas, Series, Annotations, ... and just create everything in code and add them to the appropriate collectiosn manually instead of modifying what's there. I did this without any problems:
Dim chartArea As New ChartArea("TestChartArea1")
chartArea.AlignmentOrientation = AreaAlignmentOrientations.All
chartArea.AlignmentStyle = AreaAlignmentStyles.All
Chart1.ChartAreas.Add(chartArea)
Dim legendArea As New Legend("TestLegend1")
Chart1.Legends.Add(legendArea)
Dim series As New Series("Series1")
series.ChartArea = "TestChartArea1"
series.ChartType = DataVisualization.Charting.SeriesChartType.Line
series.XValueType = DataVisualization.Charting.ChartValueType.Int32
series.YValueType = DataVisualization.Charting.ChartValueType.Int32
For Each p In New Integer() {1, 2, 3, 4}
series.Points.AddXY(p, p)
Next
Chart1.Series.Add(series)
|
|
|
|
|
Hi,
How can i list Country wise banks list in my new web app,
Thanks
|
|
|
|
|
Create a list containing the names and save it in your database. Load the list as required.
|
|
|
|
|
Thanks for your replay Richard.
But actually , i am looking for a solution like with out storing that list in my db.
so i need to know is there any web services or any other options like this available to get the world wide banks list.
eg:- as we can get the city list in a country.
Thanks
|
|
|
|
|
This is hardly a technical question, you should try Google.
|
|
|
|
|
Thanks Richard,
Please post me in case if you got any solutions .
Thanks
|
|
|
|
|
Why do you think that Richard will look for the answer for you? It's your work, not his.
|
|
|
|
|
Hi Pete O'Hanlon,
you please check my post correctly , i have mentioned in that like, 'in case' he got any answer , right?. I know it's my work.I am not asking him to do the task. k.
Thanks
|
|
|
|
|
AFAIK, there's no public list available; you'd have to make (and maintain!) your own.
|
|
|
|
|
Should also note that the solution will likely vary by country.
I suspect also that the usable definition of "bank" might vary as well.
|
|
|
|
|
Storing the data should not be too difficult.
Have two tables, one with the bank name joined to another that is contains country data.
The likely problem here is collating this data from a reliable source.
|
|
|
|
|
Hey guys, I have pretty much figured out my regression line doing some calculations, but drawing it is where I am stuck. The line comes from the y axis and goes through the middle of the chart roughly, once I get these two points I draw the line, but I do not know how to draw a line THROUGH the middle point to the end of the chart, can anyone please help me out?
Here is my chart code:
chart1.Series["Regression Line"].Points.AddXY(0, b0);
chart1.Series["Regression Line"].Points.AddXY(xAverage, yAverage);
chart1.Series["Regression Line"].ChartType = SeriesChartType.Line;
chart1.Series["Regression Line"].Color = Color.Red;
You can see the line goes from one point to another, but its only half the line, any assistance would be greatly appreciated I am completely stumped!
Many thanks!!!
|
|
|
|
|
The maths is pretty simple. If you have a line from (x0, y0) to (x1, y1) and want to extend it as far again to (x2, y2), then (x1, y1) is the midpoint of the line. x1 = (x0 + x2) / 2, etc.
Massage it a bit and you get
x2 = 2 * x1 - x0, y2 = 2 * y1 - y0.
Refactor to your variable names and that's it
Cheers,
Peter
Software rusts. Simon Stephenson, ca 1994. So does this signature. me, 2012
|
|
|
|
|
Thanks very much Peter I shall try and figure this out right now! Appreciated!
|
|
|
|
|
Peter after some experimenting, I got there, thanks to you, your equation made sense and it worked! Much appreciated!
Thank you!!
|
|
|
|
|
You're welcome.
Peter
Software rusts. Simon Stephenson, ca 1994. So does this signature. me, 2012
|
|
|
|
|
Hello. I have downloaded and used a code project sample to merge .pdf files and it's fantastic; probably saved me lots of hours of searching, testing, debugging, etc. However, I'd like to be able to put the page numbers on the bottom of a page that has landscape orientation; not portait, which is how the example is set up. Could anybody tell me how to do this? iTextSharp documentation is scant, to say the least. That's the downside of open source. Thank you.
Tom Paronis
|
|
|
|