Profile Picture

Enlarge Chart To Fill Control

Posted By Jason Gray 11 Years Ago
Author
Message
Jason Gray
Posted 11 Years Ago
View Quick Profile
Forum Newbie

Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)

Group: Forum Members
Last Active: 11 Years Ago
Posts: 1, Visits: 1
Hi All

I'm still getting used to Nevron chart so apologies if this is a dumb question

I have a NChartControl in my vb.net application. within this NChartControl I have added one NChart, However the NChart only seems to take up the middle portion of the NChartControl how do I expand the Nchart to fill the whole control to make the graph area as big as possible.

I have been doing a bit of googeling but am not sure if i am looking for the right thing. I have tried padding and margin but these have had no affect

Thanks in Advanced

Jase

Daniel Csimszi
Posted 11 Years Ago
View Quick Profile
Forum Guru

Forum Guru (50 reputation)Forum Guru (50 reputation)Forum Guru (50 reputation)Forum Guru (50 reputation)Forum Guru (50 reputation)Forum Guru (50 reputation)Forum Guru (50 reputation)Forum Guru (50 reputation)Forum Guru (50 reputation)

Group: Forum Members
Last Active: 8 Years Ago
Posts: 61, Visits: 35
Hi,

I am using C#, but I bet the methods are similar, this is my code:

m_Chart = (NCartesianChart)nChartControl1.Charts[0];
m_Chart.Location = new NPointL(new NLength(0, NRelativeUnit.ParentPercentage), new NLength(5, NRelativeUnit.ParentPercentage));
m_Chart.Size = new NSizeL(new NLength(100, NRelativeUnit.ParentPercentage), new NLength(95, NRelativeUnit.ParentPercentage));

I think the code is quite simple, basically you set the location of the graph first. Then you set the size of it, the size is set in percentage the 2 values are the width and the height.

Hope it helped
Daniel



Similar Topics


Reading This Topic