AutoCAD Inventor :: How To Select Entity From Global X Y Z Position
Dec 21, 2013
I am new to Inventor API, but have some experiences in SolidWorks API.
How can I select an entity at a given spacial point (x, y, z)? For example, I want to select a face or edge that is on a given (x, y, z) point. I can not find such an API, except for interactive selections.
I am trying to get either location, insertion point, or center of an entity that is inside of a block. I'm getting subentity using the Editor.GetNestedEntity. I create a FullSubEntityPath for highlighting, that works well, and I have looked at using GetSubEntityGeometricExtents using that same subentitypath, but not having any luck, I can't seem to find any documentation on using that method.
I know I can get the location of the owner, then calculate the location of the entity based off of that, but I'm looking for an easy way now, if that don't work out, I can do the lengthy approach.
I need to get the position and orientation of the first and the last character in a text frame art, that is, I need its matrix.There are a number of functions in the API that is supposed; here's a snippet from the file ATESuites.h
Return transformation matrix of this run.The matrix returned spesify the full transformation of the given run. You need to transform the origin by IGlyphRun::GetOrigins() and
concat with ITextFrame::GetMatrix() in order to get the location of the glyphs. ATEErr (*GetMatrix) ( GlyphRunRef glyphrun, ASRealMatrix* ret);
Hence, getting the matrix of the first character or glyph should look something like this:
But the coordinates, either returned in frameMatrix (tx and ty) or the firstPoint are obviously wrong. It appears that they an offset which is allmost constant. The x-values are approx 7664 points too large (give and take a few decimals), and the y-values are approx 7893 too large (also give and take a few decimals).
Simple example, when overrule Line entity to draw three entities Line, Text, Circle when selecting overruled Line is it possible to identify what object have been selected (in this example it could be Line, Text, Circle).
i dont want use editor (i don't want use CommandFlags.Session)
after the load in the database (see my code for xdb), i want to select all bloc within a closed line entity (within the xdb)
but how to do that whitout editor (editor..SelectWindowPolygon )
here my code for load each file , and mémorize all block for each file
Dim CollDocOuvert As New Collection For Each NomFichier In Fenetre.CollFichier 'recherche et extraction des blocs Dim Fichier As New IO.FileInfo(NomFichier) If Fichier.Exists = True Then GestionAUTOCAD.TxtOnLigneCOmmande("Gestion du
[Code]....
StatusLabelBar is a component of my form for write msg. is use me.refresh and a timer (1s) for refresh my form. (a trick i have found for do this [if you have better trick i take it.])
know if there is a command which joins GetEnttiy() and GetPoint() functions. At the moment I'm using both commands one after another. Result I want would be one command where you can choose entity or select insertion point.
I am looking for some code that would allow me to select a MTEXT Entity - or other entity - (as the DEFAULT option) but also to allow me to type in some text manually or to pick a point in the drawing. Something that would present the user with:
"Select an object or [P to pick a point]" or
"Select MTEXT or [M to type].
I can write some code to type in text manually as the default option and get the second option to select entity using get string and then write some condition of if code but I don't know how to do it having entsel as default option.
I've been working on converting a VBA macro to an Add-In (my first). I thought all was going well, but I'm struggling to share the InventorApplication object within my add-in...
All the googling I've done suggests the most suitable way is to declare it as a global variable. So I followed the work flow on this page: ([URL]......) and created a module to declare my global variables. I've then referenced this module back in the original class, but when I do, I get a message saying "modDeclarations is a type and cannot be used as an expression"..
Recently upgraded to Gimp 2.8 for the single window mode (which worksbrilliantly in Ubuntu, especially with the HUD).
But the Rectangle Select Tool has a new - but odd - behaviour. When I drawa selection, and then add to that selection, a new "square" is position atmy cursor. (See attached screenshot.) This didn't happen in 2.6 and is abit irritating because it disorientates me slightly, especially if I'mworking quickly.
Is there a way to turn that off (or revert it to the 2.6 way)?
I have written code to allow me to pick the dimensions of a part and update the dimension parameter name from a list of choices presented in a form e.g. length, width, thickness, outer_diameter, wall etc.
The parameters are exported and I can get overall sizes in the BOM with relevant expressions in columns. So far so good.
What I would like to do is have a global SIZE column in the BOM which has expressions that vary based on another custom iproperty (PartType) which defines the part. So for example if the PartType was 'circular plate' the expression in that parts row of the SIZE column would be <outer_diameter>x<Thickness> while if the PartType was 'tube' the expression in the that parts row would be <Outer Diameter>x<Wall>x<Length> etc
If I could do this I would not need different columns to define the sizes of every different type of material we use and also limit the number of parameters the user needs to choose from when picking part dimensions.
However looking at the BOM API I do not see an obvious way to alter the expressions.
I'm borrowing from the samples library in the Inventor:
Public Sub GetSingleSelection()
' Get a feature selection from the user Dim oObject As Object Set oObject = ThisApplication.CommandManager.Pick(kPartFeatureFilter, "Pick a feature") MsgBox "Picked: " & oObject.Name
End Sub
Works fine, and is fairly simple, but the problem I'm having is if I press the escape key after starting the command, but before making my selection, I'm not able to start the command again.
I realize from my searching that using the Selection (Simple) sample allows for an interrupt, with some modification, was just wondering if there was something similar for this simpler selection option.
I'm new to Maya, so this is likely something I'm just missing or that I've done without realizing it, however...
I've created a scene with a few polygonal objects. As an example, imagine a house with plants around it and a cloud above. The plants are spaced evenly along a curve, and the cloud is also made using a Paint Effect with a Modifier around it to control it's shape using slight forces, etc.
However, when it's done and I select the entire group of objects to drag to a different position, weird things happen. The plants seem to move much more quickly in that direction, so that soon they're no longer positioned where they should be at the base of the house, and the clouds move in the opposite direction from where I'm dragging (i.e. down not up). What I'll call the 'normal' polygonal objects (e.g. the house, car, etc.) all move fine, but I cannot figure out how to fix the other items so everything maintains its relative position, or lock the whole scene together to move as a group.
I've tried to combine them, and even 'parent' everything to the house, but I suspect I've changed something like a control handle position or rotated something that now moves opposite the normal xyz directions.
In 2013 SP1.1 we are noticing that when using offset in a sketch, the offset line/curve is invisible and cant be seen until a zoom is done, then it appears.
I do have a problem on SPLIT feature. I cannot seem to apply SPLIT SOLID into an entity/object but, on the other object I am able to apply SPLIT SOLID.
Sketch created using MultiBody and would like to make use of "Make Components" to create an assembly as well as parts.
I have attach a zip file of the ipt. I am currently using Autodesk Inventor Suite 2012.
I had some success transferring geometries, generated with an advanced math software, to Inventor using IGES files containing Manifold Solid B-Rep Object Entities (Type 186) (see the specification IGES5-3_forDownload-1.pdf). Now I would like to include several Type 186 entities into a single IGES file and form the geometrical unit of these (and them), for which the IGES Boolean Tree Entity (Type 180) seems to exist. I'll do some trial-and-error testing, but it would be very useful to have a (reliable) list of all IGES entities the Inventor IGES import function does or does not support (like these: Transcendata, MoldflowInsight). Unfortunately I could not find such a list anywhere.
Another question: Are the IGES import/export functions of Inventor written by Autodesk (and/)or are third-party libraries used? If the latter, which ones?
So 2011 had some issue and I though 2012 would get those fixed. I was wrong. More problems occur. With 2011 I was able to open assemblies directly through vault. Now with 2012, since the vault issue updates as it opens, I crash on any sizeable model or assembly. So now just to open a file, I must get it, then go to inventor and open it, and hit no when the refresh window come up. If I hit yes, it crashes. If I hit no it open, then if i hit local/global update it crashes. So technically I cant do any new work with any of my larger assemblies (2000+ parts) I have sent out numerous error reposrt, only for autodesk to say that they can replicate the problem. I have SP1 installed, and this is happening with other users at my company as well.
System:
Windows 7 64 Bit Solid State HD 24GB RAM Xenon Processor Nvidia Quadro FX 580
I would like to determine the Proxy ObjectType returned from Constraint.EntityOne (i.e. If oConst.EntityOne = kWorkPointProxyObject Then ....)
Property EntityOne() As IDispatch**
how IDispatch works.
Dim oAsmDef As AssemblyComponentDefinitionSet oAsmDef = oAsmDoc.ComponentDefinition Dim oConst As AssemblyConstraint For Each oConst In oAsmDef.Constraints'Below will print the Enum 67120288 (kEdgeProxyObject) or 67119520 (kFaceProxyObject) if 'it is constrained. It will Err if a Work or Sketch Proxy Object is Constrained Debug.Print oConst.EntityOne Debug.Print oConst.EntityTwo Next
I would like to instantly launch an External Rule just by clicking on a button in the Global Forms area of the iLogic browser. Is this possible, and if so, how would I do it?
Product Design Suite Ultimate 2014 | Vault Basic 2014 (SP1) Dell Precision M6600 | Intel i7-2820QM - 16GB nVIDIA Quadro 4000M | Windows 7/64 Pro
Is it possible to setup a block so that an attribute position remaines fixed (absolute to drawing) when moving the block?
I've been playing around with creating a Coordinate Block by following these instructions: [URL] ........
What I would like is to be able to set the position of the Coordinate Label and Coordinate Object independently, so that if I move one in the drawing, it doesn't move the other. I've looked into Dynamic Blocks, and the "Lock Position" parameter. I can move the attribute independently, but still everytime I move the block, the attribute moves too.
Our company uses a custom Sheet/Coordinate system to follow flyoffs across a drawing, and I'm trying to learn how to automate the process. It's completely manually right now, so any changes to a drawing creates a lot of work renumbering these flyoffs.
I will be pulling the subassemblies in as read-only parts and I would like to change the positional representation with code in the top level assembly.