Page 1 of 1

How to rotate a contour map by 90 degrees clockwise?

Posted: Tue Jul 10, 2007 2:13 pm
by 9524558
Dear Supprot

I use the following loop to add some values to a contour map. (I've taken it from some of your examples)

.
.
.

Const NX As Integer = 50 ' Grid size in X direction.
Const NY As Integer = 50 ' Grid size in Y direction.

Dim XARRAY((NX + 1) * (NY + 1)) As Integer
Dim YARRAY((NX + 1) * (NY + 1)) As Single
Dim ZARRAY((NX + 1) * (NY + 1)) As Integer

COUNTVAL = 0

For I = 0 To NX
For J = 0 tTo NY
XARRAY(COUNTVAL + J) = I
ZARRAY(COUNTVAL + J) = J
YARRAY(COUNTVAL + J) = ZVALUES(I, J)
Next J
COUNTVAL = (I + 1) * (NY + 1)
Next I
'
' Add calculated YARRAY to chart.
'
frm2DResults.TChartContour.Series(0).Clear
frm2DResults.TChartContour.Series(0).asContour.AddArrayXYZ XARRAY, YARRAY, ZARRAY

.
.
.

It seems however, that my resulting contour map is rotated by 90 degrees counter clockwise. How could I rotate it back by 90 degrees clockwise? ZVALUES(I,J) is obtained from a kriging procedure not detailed here.

Tx in advance, best regards

Andras

Posted: Wed Jul 11, 2007 8:54 am
by Pep
Hi Andras,

I'm sorry, I'm not sure what you refer here. Would you be so kind to send me a simple app. with which I can reproduce as is the problem here ?
You can send me it directly to pep@steema.com

Posted: Fri Jul 13, 2007 2:38 pm
by 9524558
Dear Pep

In the meantime I managed to solve it. Thank you for any effort to help me.

best regards

Andras