Hi,
I faced some problems in the infragistic graph in scoll bar adding.
Made the ultraChart1.Axis.X.ScrollScale.Visible = true;
but all the data coming in the same size of graph .
Is there any way to add scroll bar in the graph.
Here I am attaching the image of the graph.
Thanks In Advance.
Hello Manaswini,
Looking at the screenshot, I see that your Scrollbar is visible, but if you want to be able to scrolling, you need to "Zoom IN" your chart. You could do that with code. For example:
axisX.ScrollScale.Visible = true;axisX.ScrollScale.Scale = 0.25;
or by press "+"/ "-" signs at the left side of your scrollbar.Please let me know if you have any questions.Regards
Hello Georgi,
Thank You for replying so early.
I have used the suggestion and have the desired result.
But,the The Leveling of X axix is not showing now due to long range of data.
Is there any way to give the graph look like the following graph?
Or can we set a fixed space for each series
Thanks In advance..
Is there any alternatives to solve the scroll bar in the graph.
Would you please suggest some solutions.
Thanks in advance.
Hello ,
I am waiting for any suggestions.
Is it possible to make the y -axix static with scrollbar ?
Maybe one possible approach to achieve the desired behavior could be:
private void usbHorizontal_Scroll(object sender, ScrollEventArgs e) { UltraScrollBar scrollBar = sender as UltraScrollBar; this.ultraChart1.Left = -scrollBar.Value; axisY.Extent = scrollBar.Value + 40; double currentValue = scrollBar.MaximumDragValue / rangeValue; axisX.RangeMin = (double)scrollBar.Value / currentValue; }
private void usbHorizontal_Scroll(object sender, ScrollEventArgs e)
{
UltraScrollBar scrollBar = sender as UltraScrollBar;
this.ultraChart1.Left = -scrollBar.Value;
axisY.Extent = scrollBar.Value + 40;
double currentValue = scrollBar.MaximumDragValue / rangeValue;
axisX.RangeMin = (double)scrollBar.Value / currentValue;
}
Please take a look at the attached sample for more details. If you have any questions do not hesitate to ask me
Regards
Thanks a lot for your suggestion.
Here I am not using composite chart with the chart area property,rather just putting data from a data table to the source of the ultrachart graph.
Can we use the above code to achieve our goal,Could you please suggest?
Thanks,
Hi again,
Yes, you could use the same code. If you have any problems to implement this code in your sample, you could send it to me and I`ll make the modification. Please feel free to ask me if you have any furhter questions.
Regrads
Could you please take a look at the modifications that I made in the sample to be more similar with your scenario. You could use
ultraChart1.Axis.Y.Extent = 40; instead of axisY.Extend = 40. Please take a look at the code for more details and let me know if you have any questions.
Here i am sending my code and screenshots.
Here is the screenshot of datatable I get from a procedure.And I am using this datatable to the graph and the graph is displaying data.
uc_salesgraph.DataSource = dt;uc_salesgraph.DataBind();uc_salesgraph.Override.Enabled = true;uc_salesgraph.Axis.Y.Labels.ItemFormatString = "<DATA_VALUE:0.##>";
And the graph is coming like this.
And for scrolling I am using the suggested code .
private void usb_horizontal_Scroll(object sender, ScrollEventArgs e) { UltraScrollBar scrollBar = sender as UltraScrollBar; this.uc_salesgraph1.Left = -scrollBar.Value; //axisY.Extent = 40; //double currentValue = scrollBar.MaximumDragValue / rangeValue; //axisX.RangeMin = (double)scrollBar.Value / currentValue; }
Here for
//axisY.Extent = 40; //double currentValue = scrollBar.MaximumDragValue / rangeValue; //axisX.RangeMin = (double)scrollBar.Value / currentValue;
Its showing error as axisY , axisX , rangeValue not there in my graph.
As I am new to infragistics columnchart graph.Could you please help me regarding this.
Thanks In advance,