## NurbsSurface.Set

### Description

Sets a complete data description of the NurbsSurface. This is only available from scripted operators; if you use it on an object with some clusters and you change the topology the burden of updating the clusters is on the user. For non-scripted operators this property can only be set if the object has been frozen.

### C# Syntax

    NurbsSurface.Set( Object in_vsaUVControlPoints, Object in_vsaUKnots, Object in_vsaVKnots, Object in_vbUClosed, Object in_vbVClosed, Object in_vlUDegree, Object in_vlVDegree, Object in_veUParam, Object in_veVParam, siNurbsFormat in_eNurbsFormat );

### Scripting Syntax

    NurbsSurface.Set( ControlPoints, [UKnots], [VKnots], [UClosed], [VClosed], [UDegree], [VDegree], [UParameterization], [VParameterization], [NurbsFormat] );

### Parameters

Parameter | Type | Description
--- | --- | ---
ControlPoints | 3D Array | The control points are stored in a 3-dimensional array. The array is 4 * Number V ControlPoints * Number U ControlPoints
UKnots | Array of Doubles | An array of knot values in U direction.
VKnots | Array of Doubles | An array of knot values in V direction.
UClosed | Boolean | Specifies whether the nurbs surface is closed in U direction.
VClosed | Boolean | Specifies whether the nurbs surface is closed in V direction.
UDegree | Long | Degree of the nurbs surface in U direction.
VDegree | Long | Degree of the nurbs surface in V direction.
UParameterization | siKnotParameterization | The parameterization factor of the nurbs surface in U direction.
VParameterization | siKnotParameterization | The parameterization factor of the nurbs surface in V direction.
NurbsFormat | siNurbsFormat | Specifies how the data is formatted. Default Value: siSINurbs

### Examples

#### VBScript Example

    Dim lDegree(2), bClosed(2), eParameterization(2), aControlPoints, aKnots(2)
    set oRoot = Application.activeproject.activescene.root
    set oSphere = oRoot.AddGeometry( "Sphere", "NurbsSurface" )
    FreezeObj oSphere
    oSphere.ActivePrimitive.Geometry.Surfaces(0).Get _
            siSINurbs, _
            aControlVertex, _
            aKnots(siUDirection),aKnots(siVDirection) , _
            bClosed(siUDirection),bClosed(siVDirection), _
            lDegree(siUDirection),lDegree(siVDirection), _
            eParameterization(siUDirection),eParameterization(siVDirection)
    for i = lbound(aControlVertex,3) to ubound(aControlVertex,3)
            for j = lbound(aControlVertex,2) to ubound(aControlVertex,2)
                            aControlVertex(0,j,i) = aControlVertex(0,j,i) + 1
                            aControlVertex(1,j,i) = aControlVertex(1,j,i) + 1
                            aControlVertex(2,j,i) = aControlVertex(2,j,i) + 1
                            aControlVertex(3,j,i) = aControlVertex(3,j,i) + 1
            next
    next
    ' Create new nurbs surface list from arc data.
            oSphere.ActivePrimitive.Geometry.Surfaces(0).Set _
            aControlVertex, _
            aKnots(siUDirection),aKnots(siVDirection), _
            bClosed(siUDirection),bClosed(siVDirection), _
            lDegree(siUDirection),lDegree(siVDirection), _
            eParameterization(siUDirection),eParameterization(siVDirection), _
            siSINurbs