LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Notification of scale range change

Hello Developers!

 

Does anybody know if it is possible to determine programatically if a Waveform Graph Scale has been changed with the zoom tool or manually modifying the numbers in the scale legend? I thought the Scale range change event notifies the difference, but i cannot get it.

 

Thanks in advanced.

Regards.

0 Kudos
Message 1 of 7
(2,659 Views)

@ibvp_ss wrote:

Hello Developers!

 

Does anybody know if it is possible to determine programatically if a Waveform Graph Scale has been changed with the zoom tool or manually modifying the numbers in the scale legend? I thought the Scale range change event notifies the difference, but i cannot get it.

 

Thanks in advanced.

Regards.


you could store the scale value on a shift register and compare the before and now values to not equal to bool out a change

0 Kudos
Message 2 of 7
(2,654 Views)

Hi,

 

why do you need to know how the scale was changed?

Only idea how to do until now: Monitor the range - if only one element changed it was *most likely* done by entering a new min or max.

 

Regards

Florian

0 Kudos
Message 3 of 7
(2,643 Views)

Thanks both for the answers. I will check if it works later.

 

I need this differentiation because I am creating an Osciloscope. If the change is made manually we need to create the new scale and the new grids starting in this new point mantaining the time/division value, but if we zoom in, the programm should recalculate even the val per division.

 

Regards.

 

 

0 Kudos
Message 4 of 7
(2,617 Views)

@ibvp_ss wrote:

[...] the Scale range change event notifies the difference, but i cannot get it


 

This works for me.  What isn't working for you?

 

Example_VI_BD.png

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

0 Kudos
Message 5 of 7
(2,608 Views)

Hello Jim,

 

Yes, that works. The thing is that I cannot get the info about how was the scale modified. I need to know if the user has changed the scale manually writing down a number in the scale legend or if it has been done with the zoom tool...

0 Kudos
Message 6 of 7
(2,601 Views)

Example_VI_BD.png

 

I don't know how Rube-ish this is, but it works.  What it does is takes advantage of the fact that the zoom tool will (probably) change both axes, while typing will only change one.

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

0 Kudos
Message 7 of 7
(2,592 Views)