How can we export profile curve length?
list export did not work properly
hi @abdullahcicek
try
hi @hosneyalaa
i just want the profile curve length
I don’t want tangent length…
I want to export profile points as txt.
in this way
station Elevation curve length
0 493.648 0
100 490.455 50
200 487.739 50
300 485.062 50
400 482.158 0
491.2 480.16 0
HI @abdullahcicek
TRY
hi @hosneyalaa , @Paolo_Emilio_Serra1 , @jacob.small
I just want the “curve length” profile
I don’t want tangential length
As seen in the text below
Examble profile PVI ( station elevation curve length )
PROFIL PVI EXPORT MULTIPLE.dyn (77.0 KB)
It is faster to use.VerticalCurve to filter it
VerticalCurve Gets the vertical curve object at the pVI.
https://help.autodesk.com/view/CIV3D/2022/ENU/?guid=f2e81087-8e6e-e427-3565-b0fe5b4f1f6a
hi @hosneyalaa
does not give correct result in every way
Unfortunately…
i need a vertical curve
can you attach
An example drawing with the result you want
I have to try
If so, could you post the question in a new thread?
PLS
attach A result you want
Definitely think you should do a different thread for this subject as you are now on the Civil 3D Toolkit feedback thread. It will help get more attention to your specific issue/workflow/problem as well as help others when searching and will keep the Civil 3D Toolkit feedback for Civil 3D Toolkit’s issues
Moved to a new thread
Ok thanks @Paolo_Emilio_Serra1
try
import sys
import clr
clr.AddReference('AcMgd')
clr.AddReference('AcDbMgd')
clr.AddReference('AeccDbMgd')
#clr.AddReference('ProtoGeometry')
import clr
clr.AddReference('ProtoGeometry')
import Autodesk.DesignScript.Geometry
from Autodesk.DesignScript.Geometry import *
clr.AddReference('DSCoreNodes')
from DSCore import *
from Autodesk.AutoCAD.ApplicationServices import *
from Autodesk.AutoCAD.DatabaseServices import *
from Autodesk.AutoCAD.Geometry import *
from Autodesk.Civil.ApplicationServices import *
from Autodesk.Civil.DatabaseServices import *
from System.Collections.Generic import Dictionary
adoc = Application.DocumentManager.MdiActiveDocument
cdoc = CivilApplication.ActiveDocument
def get_sample_line_info(sampleLines):
global adoc
global cdoc
output = []
if not sampleLines:
return
if not isinstance(sampleLines, list):
sampleLines = [sampleLines]
with adoc.LockDocument():
with adoc.Database as db:
with db.TransactionManager.StartTransaction() as t:
for sampleLine in sampleLines:
sampleLineId = sampleLine.InternalObjectId
obj = t.GetObject(sampleLineId, OpenMode.ForRead)
objpv = obj.PVIs
for saPVI in objpv:
VerticalC= saPVI.VerticalCurve
if VerticalC:
output.append( str(saPVI.Station) + " "+ str(saPVI.Elevation) +" "+ str(VerticalC.Length))
else:
output.append( str(saPVI.Station) +" "+ str(saPVI.Elevation) +" "+ " " )
outputFlatten =List.Flatten(output, -1)
t.Commit()
return output
OUT = get_sample_line_info(IN[0])