Creating a NURBS surface from four corner points for a standalone C# code

Dear Forum users,

I’m new at linking C# and Rhino8. I would like to draw a NURBS surface utilizing four corner point locations. I have written a code as:

using System.IO;
using Rhino;
using Rhino.FileIO;
using Rhino.Geometry;
using Rhino.DocObjects;
using Rhino.Collections;

class Program
{
    public static void Main(string[] args)
    {

        string str2 = "C:\\Users\\SAMSUNG\\Desktop\\C#-Rhino\\Case3yeni4.3dm";

        File3dm file3dm = new File3dm();

        var point3dList = new Point3dList();

        point3dList.Add(0, 0, 0);
        point3dList.Add(0.2, 0, 0);
        point3dList.Add(0.2, 0.2, 0);
        point3dList.Add(0, 0.2, 0);

        var SrfFromPoint3dList = NurbsSurface.CreateFromCorners();

However, I cannot find a method as CreateFromCorners() recognized in Visual Studio, though it is defined in the help documentation of RhinoDeveloper.

Which method could I use to create a NURBS surface from four points given in standalone C# code not a plugin?

Best Regards,

Dear Forum Users,

I have found a way by utilizing the below code as:

    Line line1 = new Line(new Point3d(0, 0, 0), new Point3d(0.2, 0, 0));
    Line line2= new Line(new Point3d(0, 0.2, 0), new Point3d(0.2, 0.2, 0));

    Curve curve1 = NurbsCurve.CreateFromLine(line1);
    Curve curve2 = NurbsCurve.CreateFromLine(line2);

    var SrfFromLines = NurbsSurface.CreateRuledSurface(curve1, curve2);
    var id1 = file3dm.Objects.AddSurface(SrfFromLines);

Maybe, another forum user could benefit from this simple code in the future.