LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Why does x-axis change automatically?

Hi,

  I am developing a user interface to display multiple graphs based upon user selection of no. of graphs to be displayed in one window. While I was developing my application when I observed a strange behaviour.

 1) The label of x-axis (Time) disappeared (into plot area or so). I was able to re-cover it by resizing graph and plot area.

 2) The space between x-axis ticks and plot area increased

 3) I could not restore graph to previous state using right-click menu options.

 

For reference I have attached the screenshot as well. Before the problem the x-axis of upper graph was similar to the x-axis of lower graph (in screenshot). However after this problem I could not locate a way to correct it. I do not think there is any graph property using which this change may happen.  Also for me there was no reason to observe this kind of behavior.

   I had observed similar behavior in "Lab VIEW Signal Express" in which for one out of 6-graphs, the x-axis moved into plot area leaving its original location as blank.

 

Can anyone help me in getting around this problem?

 

Thanks & Regards

Mnuet

0 Kudos
Message 1 of 6
(3,119 Views)

Mnuet wrote:

 3) I could not restore graph to previous state using right-click menu options.


Have you tried "right-click...advanced...reset scale layout"?

0 Kudos
Message 2 of 6
(3,115 Views)

Hi Mnuet,

 

Do you have auto scale on for the axis?

Regards,
Claire Reid
National Instruments
0 Kudos
Message 3 of 6
(3,069 Views)

Hi,

   The problem was related with "x-scale.Top " property. I had to set this value programmaticaly in order to get rid of this problem. The auto-scale was ON for x-asis.

 

Regards

Mnuet

0 Kudos
Message 4 of 6
(3,024 Views)

Hi altenbach / Claire R / Everyone,

   I got rid of previous problem by passing value to X.SCale.Top property. However now the problem is appearing in different way. Please see attached the picture. Both graphs have same parameters/properties passed to each programmatically. But the lower graph is not only hiding the X-axis but it seems as if the lower border (of x-axis) has gone up to mid of plot area so that the y-axis is also partially cut.

   I do get my graph reset by using "advanced...reset scale layout" but this is happening at runtime. What may be the possible reason behind it? How can I avoid it by passing value to some property or invoking node etc?

Actually I resize plot area programmatically when user changes the no. of graphs to be displayed in a fixed height pane. While reducing size below a certain threshold, I also change X-axis style so that X.scale markers are hidden (X-axis style changed to 2 from 0). Now even if I change X.axis style programmatically, the x-axis does not show up (or is not hidden) while moving back and forth.

  You help will be highly valuable for me.

Regards

Mnuet

0 Kudos
Message 5 of 6
(2,980 Views)

You don't expect your mechanic to diagnose your car problems of you mimic the bad sound over the phone, so don't expect us to troubleshoot a program by looking at a picture. 🙂

 

SO: Please make a simple VI that shows the problem and attach it here. Also include steps to reproduce the problem. Thanks! 🙂

0 Kudos
Message 6 of 6
(2,965 Views)