Quinn-Curtis Forums
Quinn-Curtis Forums
Home | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Tools for Microsoft .Net
 Real-Time Graphics Tools for .Net (VB and C#)
 Specifying Tick Marks in Graph

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Screensize:
UserName:
Password:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkInsert EmailInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
   

T O P I C    R E V I E W
bechbd Posted - 31 Oct 2005 : 13:29:59
I am having a problem specifying the length between tick marks on the x axis of the graph. I initially set them to ChartObj.TIMEAXIS_5SECONDSECOND when I declare the xaxis. The problem is that when I display the graph the major tick marks are at 10 seconds. I had a similar problem to this with the normal graphing and it was due to autoscaling the x-axis. I tried setting the xaxis.ScrollScaleModeX=RT_NO_AUTOSCALE_X but when I do this the graph no longer scrolls across the screen once more than on screens worth of data is shown. How can I specify the major tick mark spacing and still have the screen scroll?
4   L A T E S T    R E P L I E S    (Newest First)
bechbd Posted - 31 Oct 2005 : 15:31:50
Thanks that worked beautifully.
quinncurtis Posted - 31 Oct 2005 : 14:37:57
In order to scroll the x-axis the ScrollFrame must auto-scale the related axes, using our own algorithms for the axis tick marks. If you want something other than the default values that we choose you must override the AxisTickMarkTimeBase property between the ScrollFrame's autoscale and the ChartView.UpdateDraw call.

First, turn off the ScrollFrame's AutoRescaleFrame property after you create it, as seen below.

scrollFrame = new RTScrollFrame(this, currentTemperature1, pTransform1, ChartObj.RT_FIXEDEXTENT_MOVINGSTART_AUTOSCROLL);
.
.
.
scrollFrame.AutoRecaleFrame = false;	
chartVu.AddChartObject(scrollFrame);	



Then, where you call the ChartView.UpdateDraw method, insert a call to
scrollFrame.RescaleFrame(), and explicity set the axis AxisTickMarkTimeBase property. Setting the AxisTickMarkTimeBase property MUST take place betweent the ScrollFrame.RescaleFrame call the the ChartView.UpdateDraw call.

private void timer2_Tick(object sender, System.EventArgs e)
{
	if (this.IsDesignMode) return;			
	scrollFrame.RescaleFrame();
	xaxis.AxisTickMarkTimeBase = ChartObj.TIMEAXIS_5SECONDSECOND;
	this.UpdateDraw();		
}

bechbd Posted - 31 Oct 2005 : 14:23:42
Yes I'm sorry I mean the scrollframe object.
quinncurtis Posted - 31 Oct 2005 : 14:20:20
The axis objects to not have a ScrollScaleModeX property. Are you talking about a ScrollFrame object ?

Quinn-Curtis Forums © 2000-2018 Quinn-Curtis, Inc. Go To Top Of Page
Powered By: Snitz Forums 2000 Version 3.4.07