How can I make a Loft / CurveSeam Script to work without having to Pick the curves manually

How do I grab the curves In The Script after the CurveSeam action has run ? I mean without to do it manually…

import rhinoscriptsyntax as rs

surface1 = rs.GetObject("Select surface 1", rs.filter.surface | rs.filter.polysurface)

Border1 = rs.DuplicateSurfaceBorder( surface1 )
Border1fix = Border1
if rs.IsCurveClosed(Border1fix):
    domain = rs.CurveDomain(Border1fix)
    parameter = (domain[0] + domain[1])/2.0
    rs.CurveSeam( Border1fix, parameter )
Border1fixx = Border1fix

surface2 = rs.GetObject("Select surface 2", rs.filter.surface | rs.filter.polysurface)


Border2 =  rs.DuplicateSurfaceBorder( surface2 )
Border2fix = Border2
if rs.IsCurveClosed(Border2fix):
    domain = rs.CurveDomain(Border2fix)
    parameter = (domain[0] + domain[1])/2.0
    rs.CurveSeam( Border2fix, parameter )
    Border2fixx = Border2fix
    border = (Border1fixx, Border2fixx)

Please help me out

Hi Harvid22,

If you add a last line:


the 2 curves are selected, is that what you are after?