Measurement Studio for VB6

cancel
Showing results for 
Search instead for 
Did you mean: 

cwgraph3d axes labels question

Is there a way to have the axes labels different than the auto. For example. I want to plot a 10 by 10 array. However I want the graph to show the axes and tick marks and have them show that the data is 40 cm by 40 cm instead.
0 Kudos
Message 1 of 6
(6,998 Views)
You can do this with the CWAxis3D FormatString property. You can get to this in the property pages via the Format tab. For example, I think the format string *4" cm" would display what you're looking for.

- Elton
0 Kudos
Message 2 of 6
(6,989 Views)
attached is a sample of what I am trying to do. As you can see when the form first loads, the labels are from the bottom left to the top and right respectively increasing. Thats how I want the labels to be all the time. However, once the graph is moved or the plot is generated, the labels go to the other sides (I don't want this).

Another thing I still dont' know how to do is to make the range go from lets say 0 to 300 even though this range is -4 to 4 with the generated plot. I want the labels to make it say 0 to 300 instead. How would I use the formatstring property in this way.

Attached is my modified version of the sample included in the measurement studio library.
0 Kudos
Message 3 of 6
(6,944 Views)
Hello,

I looked at your .zip file that you attached to the post and it looks like it contains the VB Project but not the Form, so I was not able to see your code. If you would like to attach your VB Form to this page I would be more than happy to take a look at it.

Regards,
Kevin L.
Applications Engineer
National Instruments
0 Kudos
Message 4 of 6
(6,922 Views)
Sorry, Here you go.
0 Kudos
Message 5 of 6
(6,915 Views)
Hello,

If you want to change the axis range on your plot, I would use the properties CWGraph3D.Axis.Minimum and CWGraph3D.Axis.Maximum. For example you could call something like:

Private Sub Form_Load()
Set axis = CWGraph3D1.Axes.Item(1)
axis.Minimum = 0
axis.Maximum = 300
RefreshControls
End Sub


With regards to your other question, it is part of the CWGraph3D control that the labels move when the graph is rotated and I believe that can not be changed. Also, I did not notice that when the graph was loaded that any of the labels changed position.

I hope that his information helps you out.

Regards,
Kevin L.
Applications Engineer
National Instruments
0 Kudos
Message 6 of 6
(6,883 Views)