Code Red > .NET

Pline jig with double

<< < (2/3) > >>

Jeff_M:
Atook, thanks but I don't think it's that simple. The ppResult.Status = OK every time the cursor moves. I only want to get the elevation from the user when they Pick a point.

ANd as I was typing this I realized I need to do this in the code which calls the ed.Drag() when that Result is OK. Will report back with what I find... Thanks!

Atook:
Hmm... I thought ppr only returned when the user clicks, I'll have to look at the complete implementation of my jig.

That code is pulled from I jig I use that prompts the user for an angle after they click to insert a block. I may have simplified it too much for this post.

Curious to see what you come up with.

Jeff_M:
OK, this is now working as I had hoped. I have a global Point3dCollection, _vertices, that I add each polyline vertex created with the user entered elevation. It is much simpler than I had thought it would be (as usual, it seems).


--- Code - C#: ---//portion of the command code which constructs and calls the Jig            while (true)            {                PromptResult res = ed.Drag(jig);                switch (res.Status)                {                    // New point was added, keep going                    case PromptStatus.OK:                        jig.AddDummyVertex();                        _vertices.Add(getElevatedPoint(ed, jig._tempPoint)); //<<<<Added this line, had to set the _tempPoint to public in the jig class                        break;                     // Keyword was entered                    case PromptStatus.Keyword://remainder of code unchanged from Kean's example 

The getElevatedPoint function handles the ed.GetDouble(), and has options as well to set by elevation/grade/slope/difference, with the end result being the elevated point for use later with the featureline.

Jeff_M:
ARGHHH. So I hadn't noticed that the jig disappears while it is asking for the elevation...now to figure out why that is.

Jeff H:
I've got one that automatically fillets polyline as you draw it and had to drop the jig and just did it with prompting and using Editor.Command.
If you like I can dig it up and post it.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version