AutoCAD .NET :: Loop While Getpoint Succeeds

Nov 25, 2009

How to loop until user quits picking points (escapes) this works but don't know if there's a better way

Dim bGotPoint As Boolean
bGotPoint = True
Do While bGotPoint = True

[Code] .......

View 9 Replies


ADVERTISEMENT

AutoCAD .NET :: Transparent Commands During GetPoint?

Sep 25, 2012

I'm using Application.ShowModalDialog to display a modal form to the user launched from a button on a tab in a PaletteSet.  The modal dialog lets the user click a button to select a point.  Is there any way that I can let the user run transparent commands and still return to the modal dialog?  

The ideal would be for the user to be able to zoom and pan transparently from the GetPoint prompt.  I could also provide a button to allow the user to reposition the drawing.

Using edUsrInt As EditorUserInteraction = ed.StartUserInteraction(Me.Handle) ' Get the insertion point from the userDim prPtOpts As New Prompt Point Options(vbLf & "Select center point: ") prPtRes = ed.GetPoint(prPtOpts)transientGraphic = DrawTransientGraphic(prPtRes.Value, BlockScale) edUsrInt. End()Me.Focus() End Using

View 4 Replies View Related

AutoCAD .NET :: GetPoint Method Is Cancelled After Displaying Preview

Aug 16, 2012

I display Preview, then modal form with some options.

One option needs select window but I receive *Cancel* in command line.

If I try to select a window again, everything works OK.

If I disable displaying Preview, it works fine, but function is useless for my purposes

[URL]

I tried Regen, UpdateScreen, etc. after displaying Preview but with no effect.

View 4 Replies View Related

AutoCAD Visual LISP / AutoLISP :: How To GETPOINT Via Mouse Click Only

Dec 22, 2011

I am trying to limit the input that can be processed when using the getpoint lisp function.  So the code below prevents the user from entering null input (i.e just hitting a carraige return) as specified by the initget bit code of 1, or a non-numeric entry (i.e. for instance, typing S and hitting a carriage return) as the getpoint function does not allow for a non-numeric entry.

    (initget 1)
    (setq PT1 (getpoint "
Pick Location of First Point: "))

However, the issue is that the code does NOT prevent the user from entering a number and hitting return.  For instance, if I enter the number 100 and hit return, getpoint accepts this as a valid entry and returns a point value that is projected, in some form or fashion, from I believe the last entered point or (0,0,0) if a point was not previously entered.  I only want the user to be able to select a point with a mouse click and not type in a number or point coordinate.

So is there some way with AutoLISP or Visual Lisp that you can prevent the user from typing in a numeric value and hitting a carraige return in conjuction with the getpoint function?  Or is there some other function that will provide the getpoint functionality while providing the entry limitations described?

View 9 Replies View Related

AutoCAD .NET :: Get Specified Attribute From Block Without Loop

Aug 9, 2012

I know how to get/set attribute within loop at block's AttributeCollection.But I'm wonder if I can set value for specified attribute without loop. Or I always have to iterate on each attribute in block's AttributeCollection?

View 9 Replies View Related

AutoCAD .NET :: How To Break Loop For Enter Key

Mar 9, 2012

I tried the following code posted in the forum, but i need to know how to break the loop when right click/ Enter Key is pressed.

Following is the code i used:

Dim acDoc As Document = Application.DocumentManager.MdiActiveDocument
Dim acCurEd As Editor = acDoc.Editor

 [Code]....

View 2 Replies View Related

AutoCAD .NET :: How To Iterate Through Polyline3D Vertices With For Loop

Feb 5, 2013

I know I can use the following...

...Polyline3d pl3d = acEnt as Polyline3d;foreach (ObjectId id in pl3d){ PolylineVertex3d plv3d = tr.GetObject(id, OpenMode.ForRead) as PolylineVertex3d; Point3d p3d = plv3d.Position; ...}
 
But I need to work with "for" loop.It seems "pl3d[i]" does not work.Is there other ways to iterate through Polyline3d vertices?

View 3 Replies View Related

AutoCAD .NET :: Unwanted Zoom In Loop Command

Feb 12, 2013

I have a portion of my routine below. Basically I need the user to continue to loop through the command. They are picking Circles or blocks in the drawing and I get the insertion point, then insert a new block. However, whenever they try and use a transparent zoom or pan to move around the drawing when the promptentityresult is hit, it zooms back to the original location.

Here is a code....

<
CommandMethod("getpnt", CommandFlags.Session)> _
Sub findpnt()
Dim cnt AsInteger = 0
Dim NEWPNT AsPoint3d = GetInsPoint()
While cnt < 3

[Code] .......

View 5 Replies View Related

AutoCAD Inventor :: API To Get Inner And Outer Loop Of Sphere

Mar 6, 2013

I have a sphere body whose material is partly removed by a boolen subtraction with another sphere. When I query the EdgeLoop of sphere for Outer edge loop using function InvEdgeLoopPtr::GetIsOuterEdgeLoop(), I always get a value of VARIANT_TRUE. check for the inner and outer loop of a sphere? use the attached file for reference.

View 3 Replies View Related

AutoCAD 2010 :: Hangs Up And Get Caught In Loop?

Aug 10, 2013

I have AutoCAD 2010. When I start it up, and draw simple lines in the drawing editer and then try to save the drawing,

AutoCAD gets hug up in a loop, and stops working.

I have tryed the repair option and I have reinstalled AutoCAD serveral times, and it still has not repaired the problem.

I need AutoCAD 2010 to do work.

View 4 Replies View Related

AutoCAD Inventor :: Close Loop Function

Oct 23, 2012

Have sketched the geometry for an 18 tooth circular sawblade. However I have had difficulty applying the close loop function. As a result am not yet able to extrude the saw blade. What to do to implement close loop?

View 4 Replies View Related

AutoCAD 2010 :: How To Make Line Intersection Into Loop Or Dot

Jul 10, 2013

I know we can do this easily in AutoCAD Electrical, but I could not find any command or feature in AutoCAD to set up this function so that when two lines are intersected, the cross point will become a dot or loop.

View 9 Replies View Related

AutoCAD 2010 :: Stuck In Plot Preview Loop

Oct 26, 2009

AutoCAD 2010 SP2:

Upon setting up a drawing for plotting (the problem is not printer specific) the "Print Preview" gets stuck in a loop where I am unable to exit if I choose to cancel or alter the settings. I am forced to go ahead and send the plot. If iI immediately go back and run the PLOT command again nothing happens... no dialog box, no error nothing. I must then go to any other open dwg, do a save, and then go back to the original dwg. Then the PLOT command will again work, however, still getting stuck in the preview loop.

View 8 Replies View Related

AutoCAD .NET :: Display Inserted Blocks While Inside A Loop?

Sep 18, 2011

I am asking the user to select points and insert a block at each of the selected points. On user exit from the point selection I draw a polyline connecting the blocks.

However, I cannot get the already inserted blocks to display until I complete the insertion of all blocks.  How do I go about getting them to display as soon as they are inserted? The code segment below is inside a transaction and nothing appears on the screen till this transaction is committed' Pt(0 to 2) is defined as a double and is returned when the user selects a point with function

SelectPoint Do While SelectPoint(Pt) = True Dim MyPoint3D As New Point3d(Pt(0), Pt(1), Pt(2)) InsertBlockAtPoint(MyPoint3D, myTransManager, strBID, _ myBlockTable, CurrentBlockSpace, dwg, True)' strBID is a previously populated structure containing data about the block insertion details and Xdata to be added to the block reference Dim MyPolyPoint3D As New Point3d(Pt(0), Pt(1), 0) myPoints.Add(MyPolyPoint3D)' myPoints is a data set used to plot the polyline

[code]....

View 7 Replies View Related

AutoCAD Inventor :: Loop Through Specific File In Folder

Jul 19, 2013

I am trying to create a logic rule to replace the model reference in a idw file and then save as using the new file reference name. I am able to do this for individual files or components within an assembly file.

However what I would like is to check through all files of a certain type (for example ipt with filenames beginning "SSUA" ) in a specific folder. 

The following code from Curtis Waguespack works well for individual selected files but I would like to take it a stage further with the above parameters.

Dim oDoc as DocumentoDoc = ThisDoc.DocumentDim oRefFile As FileDescriptorDim oOrigRefName As Object For Each oRefFile In oDoc.file.ReferencedFileDescriptors'get the full file path to the original internal referencesoOrigRefName = oRefFile.FullFileName'present a File Selection dialogDim oFileDlg As inventor.FileDialog = NothingInventorVb.Application.CreateFileDialog(oFileDlg)oFileDlg.InitialDirectory
[Code]........

View 3 Replies View Related

AutoCAD Inventor :: VB To Change Filename As Loop Progresses

Jun 8, 2012

I have VB code that loops through and utilizes Excel data to pick which file(s) to open, update, and close.  Then it opens the appropriate .idw file, updates it and saves it as a .pdf. 

The line of code I have now is simple:

_invApp.ActiveDocument.SaveAs("C:UsersxxDesktopA60.pdf", True)

and that writes the file to my desktop as a .pdf.

However, as the loop runs over and over, it will find another data set that is the same A60 type, so it will want to save OVER that .pdf it's already created.

How do I go about having a variable filename?  Something where it would add a _01 _02 _03 (or similar) to the end of the filename (i.e. A60_01.pdf, A60_02.pdf). 

View 1 Replies View Related

AutoCAD Visual LISP / AutoLISP :: While Loop With Prompt

Nov 19, 2013

I am trying to put together a loop to enter a number greater than the previous number entered. Below is my mockup and I just cannot get it.

(defun c:22 () (while (setq d (getreal "
Specify diameter: ")) (setq $d d) (while (if (<= d $d) (progn (prompt "
Specify greater diameter.") (setq d (getreal "
Specify diameter: ")) ) ) ) (setq p1 (getpoint "
Specify point: ")) (command "CIRCLE" p1 d) ))

View 9 Replies View Related

AutoCAD Inventor :: ILogic FOR Loop To Unsuppress Features

Sep 10, 2013

I am currently designing a heat exchanger and want to adjust the number of water channel using iLogic. The number of channels to be active is based on the channel dimensions, and is calculated in my excel spreadsheet, but up to a maximum of 19. This is stored in the parameter "no_channel". Each channel is a seperate feature (extrusion) and named from "Channel 1" though "Channel 19".

My idea of doing this automation was to have iLogic suppress all the features, and then doing a closed loop to unsuppres the features I want active:
 
Feature.IsActive("Channel 1") = FalseFeature.IsActive("Channel 2") = False...Feature.IsActive("Channel 19") = FalseFor i = 1 To no_channelFeature.IsActive("Channel"(i)) = TrueNext
 
However, this gives me the following error:

Error in rule: Number of channels, in document: Radiator fin side.ipt

Feature.IsActive: No feature found with the name: "h".

View 2 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Add Nil - Stop While Loop?

Oct 22, 2013

I am have trouble trying to figure a couple of things in the following code.

First - in the IF statement if "SD" is >= ask "Specify LAST strata number". How do I add nil?
Second -  After I "Specify the LAST strata number", How do I stop the loop?
 
(defun C:22 () (setvar 'osmode 0) (or $S (setq $S 10)) (setq S (getdist (strcat "
Specify scale [Inches equal a Foot] <"(rtos $S 2 2)">: "))) (if (= S nil) (setq S $S)) (setq $S S) (or $BD (setq $BD 7)) (setq BD (getdist (strcat "
Specify boring depth in feet <"(rtos $BD 2 2)">: ")))
[Code] ........

View 2 Replies View Related

AutoCad 3D :: Flexi Curvy Loop Of Flip Flop

Mar 27, 2012

I have been using AutoCAD mainly doing shopfitting and construction drawings; occasional 3D presentations. Therefore I am clueless as to how to start drawing something like e.g. the flexi-curvey loop of a flip flop in 3D.

View 9 Replies View Related

AutoCAD Inventor :: How To Heal Error For Loop Orientation

Jun 6, 2012

I'm desperate to know how should i heal the errors for loop orientation issues. I had imported the .stp file into inventor so i can do stress analysis. After imported the file and enter into repair environment, after i find the errors shown 9 errors in loop orientation issues. 

View 1 Replies View Related

AutoCAD Inventor :: How To Select Chain Loop On Chamfer

Aug 12, 2013

I wanted to chamfer a poligonal faced part, but had to select the edges one by one.

The Edge Chain buttons were grayed out, why?

View 1 Replies View Related

AutoCAD 2010 :: Activating Account Resend Loop

Jan 24, 2012

I recieved my serial # and product key.

But I can't apply it because the site states my account has not been activated. It places me into a loop to resend to my email to activate my account. I'm in a never ending loop.  There seems to be a glitch to the site.

View 3 Replies View Related

AutoCAD Inventor :: How To Stop ILogic Loop With Keyboard

Sep 27, 2011

Is it possible to stop an infinite loop when running an iLogic rule?

View 4 Replies View Related

AutoCad 2D :: Grading Plan For RAMP And Loop For Bridge

Oct 27, 2013

Looking for grading plan for RAMP and Loop for bridge.

View 3 Replies View Related

AutoCAD Inventor :: Loop Select Sketch To Create Boundary

Sep 26, 2011

I am not sure exactly why this is a limited feature of Inventor 2011 but when you want to select a sketch to create a boundary patch you have to select each part of the sketch in sequence.  It's a pretty laborious task.  I am looking to a way to automate this using i logic. 

View 5 Replies View Related

AutoCAD Inventor :: Split Face Open Loop Error

Dec 16, 2013

I am attempting to split a face so I have a good area to apply a load in simulation and 3/4 of the areas split just fine but I CANNOT get the 4th area to split! This is all just projected geometry but left and right are symmetrical so I can't figure out why the L side works but not the R side.

View 2 Replies View Related

AutoCAD Inventor :: Redefine Center Point Of Loop Of Edges?

Mar 10, 2012

way to redefine a point that was placed in a model with a "Center of Loop of Edges" command?  Inventor doesn't seem to recognize type of placement unless it's been selected from the Point drop-down menu, but picking this in the midst of a redefine only creates a new point, it doesn't redefine the original point.

As it is, I've been forced to just delete the original point, create a new one and go from there.

Infrastructure DSP '14 / Product DSP '14 / Vault Professional 2014
Dell Precision T1650
Windows 7 Professional SP1 64-bit
Intel E3-1270 V2 3.5GHz / 32G RAM
Nvidia Quadro 2000, Driver 331.82
Space Navigator, Driver Version 6.17.7

View 2 Replies View Related

AutoCAD Inventor :: Roller Chain Generator Without A Closed Loop?

Dec 20, 2013

I'm designing a lift truck with a "chain over" lift - the lift cylinder has a sprocket mounted on the end of the rod, and the chain is grounded on one side.  The other end of the chain is mounted to a lifting carriage so that as the cylinder extends and pushes the sprocket up, the chain rolls over it and the carriage moves up (at twice the speed of the cylinder).  This is nothing new - it's pretty much how every single fork truck in the world operates.

My question is this:  can I use the roller chain generator to model this chain, or should I model the links and array them along a path?  My thinking is that if I can use the chain generator, I should be able to animate the chain using Dynamic Simulation.  But the chain generator seems to require a minimum of 2 sprockets in order to work - there's no way that I can see to have a "non-looped" chain or any way to just ground the end of the chain.

2014 Product Design Suite
W7Pro-64
Intel Xeon E5-1620 @ 3.60 GHz 16GB RAM
Dual 1GB NVIDIA Quadro K600 graphics

View 4 Replies View Related

AutoCAD Inventor :: Creating Wire Loop Between Two Connector Pins

Sep 27, 2011

I'd like to use the Cable and Wiring tools to model some fibre optics. I can see how this could work well, being able to set and check for the minimum bend radius. However, I'd also like to include a loop of greater than minimum bend radius between the two connection points, we tend to do this to reduce strain on the fibres. Any elegant solution for inserting the loop?

View 3 Replies View Related

AutoCAD Inventor :: ILogic Rule To Measure Loop Length

Oct 30, 2013

I have just started to use ilogic, what i want to do is measure the length of a loop in a sketch and then use this measurement as a parameter.

I have found this rule that will measure the loop length and display it in a message box

Dim se As SketchEntity = ThisDoc.Document.ComponentDefinition.Sketches(1).SketchLines(1) 
MsgBox(ThisApplication.MeasureTools.GetLoopLength(se)*10 & " mm") 

but i do not know how to capture the measurement as a parameter .

View 3 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved