.. highlightlang:: us .. index:: auto_xyz_CrossSectionXY .. _auto_xyz_CrossSectionXY: auto_xyz_CrossSectionXY ======================= .. us.tag auto_xyz_CrossSectionXY ENGLISH auto_xyz Changed5400 :ref:`auto_xyz_CrossSectionXY` creates a new dataset by by calculating the z coordinates for the given curve coordinates. .. function:: hDataNew = auto_xyz_CrossSectionXY(hData, hData2, nType) hDataNew = auto_xyz_CrossSectionXY(hData_Layer, hData2, nType) .. us.return **Return Value** *hDataNew* is the handle of the new 2D dataset. .. us.params **Parameters** .. uparam:: hData_Layer *hData_Layer* is a vector with one or two elements: .. list-table:: :header-rows: 1 * - Value - Meaning * - hData_Layer[1] - Handle of a dataset. The new dataset is added to the diagram to which the dataset hData_Layer[1] belongs. * - hData_Layer[1, 2] - The first element is the handle of a dataset and the second element is the handle of diagram (layer). The new dataset is added to the diagram with the handle hData_Layer[2]. .. uparam:: hData2 *hDataXY* is the handle of a 2D datasets. .. uparam:: nType *nType* is one of the following values: .. list-table:: :header-rows: 1 * - Value - Description * - 1 - The x-coordinates are the projection on the x axis. * - 2 - The x-coordinates are the projection on the y axis. * - 3 - The x-coordinates are the curve length values. .. us.example **Example** The following example will creates a cross section at the specified coordinates: :: auto_AddToUI("Examples", "Example 1: Map Cross Section", "RS_Example_CS"); def RS_Example_CS() { MessageBox("In the following dialog please select the file map-data.xls"); auto_SetFileNameDialogInit("*.xls", GetRootDirectory() + "samples/"); svFile = auto_GetFileNameDialog(1); if (svFile[1] == "DLG_CANCEL") { return; } hPage = auto_LoadTemplate(GetRootDirectory() + "samples/automate/Example.ipw"); auto_ImportData(svFile[1]); hData1 = auto_LoadDataset("Diagramm 1", "N", "EWGMOM", "BEEWG"); hLayer1 = PageGetLayerHandle(hPage, "Diagramm 1"); rmXY = [1200, 20; 1600, 50; 2200, 30; 2600, 80]; hDataXY = auto_xy_CreateDataset(hLayer1, "Curve", rmXY[;1],rmXY[;2]); hLayer1 = PageGetLayerHandle(hPage, "Diagramm 2"); hDataNew = auto_xyz_CrossSectionXY([hData1, hLayer1], hDataXY, 1) auto_ScaleAxes(); auto_UpdatePage(TRUE); } .. us.history **History** .. list-table:: :header-rows: 1 * - Version - Description * - 5.70.6 - Documentation addd. .. seealso:: :ref:`overview-automation`, :ref:`auto_LoadDataset` :sub:`id-122829`