Associating normalizedCurveParameter of PointOnCurve with family parameter

Associating normalizedCurveParameter of PointOnCurve with family parameter

Anonymous
Not applicable
366 Views
3 Replies
Message 1 of 4

Associating normalizedCurveParameter of PointOnCurve with family parameter

Anonymous
Not applicable

I have a family parameter with formula. 

I have a point on curve. Now I have to associate NormalizedCurveParameter of that point on curve and that family parameter with formula.

When I draw a point on curve manually , it looks smaller than a reference point, also the parameter looks different than parameter for a referencePoint. Is there a API way to draw point on curve? Because I am not getting hold of

Parameter called “normalizedCurveParameter”.

Also I need to use

Doc.familyManager.associateElementParameterToFamilyParameter........

 

Please refer me to a code sample.

Many thanks in advance!

 

0 Likes
367 Views
3 Replies
Replies (3)
Message 2 of 4

BardiaJahan
Advocate
Advocate

I believe the point being smaller means it is not a driving point. Basically you cannot drag and move it and it does not drive any other element's location. I replied to your other question about the NormalizedCurveParameter, hopefully that answers your question. 

0 Likes
Message 3 of 4

Anonymous
Not applicable

Many Thanks! 

0 Likes
Message 4 of 4

FAIR59
Advisor
Advisor

here's an example

ReferencePoint pnt; //  referencepoint on Curve
Parameter p = pnt.get_Parameter(BuiltInParameter.POINT_ELEMENT_NORMALIZED_CURVE_PARAMATER);
FamilyParameter famP = doc.FamilyManager.get_Parameter("myPointDrivingParameter");
if(p==null || famP==null) return;
			
using (Transaction t = new Transaction(doc,"associate parameter"))
{
	t.Start();
	doc.FamilyManager.AssociateElementParameterToFamilyParameter(p,famP);
	t.Commit();
}