AutoCAD VB :: Cannot Select Block Reference Using SelectAtPoint Method
Apr 24, 2011
I try to get a blockreference name and objectID by selectatpoint method in VBA, but i fail to do that.
dim obj as object
dim blkRef as acadblockreference
sset.selectatpoint(point)
for each obj in sset
set blkRef=obj
msgbox blkRef.name
next obj
just like that above, but noting returned. I do not want to use selectbypolygen method.
View 1 Replies
ADVERTISEMENT
Nov 29, 2012
I have a drawing with many block references on it and they have some attributes.
I know how to find the block reference witch the attribute value, and even change it but I don't know how to select it once I have the object ID of the block.
How can I do the selection without asking the user to select it?
View 6 Replies
View Related
Nov 18, 2013
C#.NET
I want to use select on screen method with Filter type only for "TEXT".
Mean I want to select only TEXT from the Selection set so how it can be possible ?
I am not able to write the statement for the Filter Type.
Post the statement in C#.NET if possible.
View 2 Replies
View Related
Oct 21, 2013
I'm trying to change block the definition of an block reference.
I did something like this:
blockreference.BlockTableRecord = newBlock.ObjectId;
In most cases this works well. However I found a case that it not work as well. When I try to change the definition from a new block that I have created in my test DWG, it disappears from the model.
View 6 Replies
View Related
May 3, 2012
I have a block: “Block_A”. I am trying to determine if a block reference of the block exist.
Currently I would iterate every block Reference in the Block Table, and then dig deep into each block ref . . . . .
I was wondering if I could just take “Block_A” and see if it has reference and where the references are. Perhaps this is just wishful thinking but I was hoping for a faster way to obtain the references then to iterate thousands of blocks in each table record.
View 4 Replies
View Related
Nov 17, 2012
Drawing contains a block with "BlkName". I want to insert blockreferences of this existing block using .Net. All shows how to insert a new block and then use the BlockID returned by the insert function. In my case I only have the block name and there is no Block id. How to get it or how to create a block reference of an existing block?
View 3 Replies
View Related
Jul 4, 2013
When pasting a block from a drawing to a second drawing using the clipboard method the block pasted in with components of block in different area of drawing but still linked together. This even happened in the same drawing.
View 9 Replies
View Related
Nov 12, 2012
if there is a plugin or a way to select all the invisible layers from a photoshop file autmatically with just one click?This would be really handy when it comes to huge photoshop files with lots of folders & layers...
View 4 Replies
View Related
Jun 22, 2012
I have a series of logos that we use. I would like to have them setup in a dynamic type block that would allow us to select the block and choose from a pull down that logo to use.
I have see it done before just don't know how to replicate it.
As you scrolled through the choices as each one was highlighted it would display that one on the screen.
View 5 Replies
View Related
Mar 29, 2013
I need to get list of all block reference in a drawing without iterating through all entities in the drawing.
View 7 Replies
View Related
Jan 11, 2013
I have a weird problem with exploding block reference with vb.net as follows.
When I use BR.explode(DBObjectCollection), and append the entities in the object collection to model space,
the 3d Polylines inside the block reference do not get appended and I do not get any kind of error. The reason for this eludes me as of yet. (remember, simple polylines and lines and other objects do get appended to model space)
When I use BR.explodetoOwnerSpace(), the block reference explodes as it normally is expected to, but then I have no way to collect the objects from the exploded BR.
View 9 Replies
View Related
Sep 27, 2012
I'm working with two different drawings to import Layers for Lot Grading and when I'm importing the Block Reference from the origin file, it's setup as Linescale 0.5, but when I import into my regular basemap, which is setup for Linescale 1, the text size is double what it should be.
View 1 Replies
View Related
Oct 22, 2013
I'm trying to write a vb script to extract information from the CAD drawing. While testing, i found that for some drawing blocks, the corresponding AcadBlockReference Rotation returns 1.57, but when i look at the actual drawing, block properties, the rotation is 0.
View 3 Replies
View Related
May 11, 2010
i need to use something with similar effect to Editor's method SelectCrossingWindow, but i need it to select object in Block Reference. How can i do that?
View 5 Replies
View Related
Jul 13, 2012
I have a block reference in a dwg that is a like a form, for example:
Written By: Diogo
Author: Diogo
Date: 13-07-2012
State: Check-in
In autocad this is a block, and on the attributes of the block reference I only can edit State and Author, and i would like to get all values. Because i want to fill those values of Written By, Author, Date and State by code. I can reach the attribute collection of the block but i only can see the State and Author.
View 7 Replies
View Related
Jun 14, 2011
is ter any way to explode a reference block
View 4 Replies
View Related
Aug 2, 2013
I wonder if this can be done. i have a number of blocks which have labels to them i.e. JW1, JW2, JW3 etc. which corresponds to the block name. Is it possible to have the label automatically referenced to the block name so if i change the block name to JW10 the label within the block changes to JW10 as well.
View 4 Replies
View Related
Mar 21, 2013
I get a block reference (has attribute) from other drawing as code follow:
Public Sub GetBlock_Info() Dim blockName As String = "test" Try Dim doc As Document = Application.DocumentManager.MdiActiveDocument Dim doclock As DocumentLock = doc.LockDocument() Dim ed As Editor = doc.Editor Dim ofd As New OpenFileDialog("Select Drawing", Nothing, "dwg; dwt", "ATS detai drawing", Autodesk.AutoCAD.Windows.OpenFileDialog.OpenFileDialogFlags.DoNotTransferRemoteFiles) Dim dr As
[code]..........
View 9 Replies
View Related
Sep 9, 2013
i have a .dwg fille with some block reference.
I want to fill color for block reference, but when I debug to hatch.appendloop function, I get message eInvalidInput, and block don’t fill color.
This is my
[CommandMethod("FillColor")]
public void FillColor()
{
Document doc =
Application.DocumentManager.MdiActiveDocument;
Editor ed =
doc.Editor;
Database db =
HostApplicationServices.WorkingDatabase;
Transaction tr =
db.TransactionManager.StartTransaction();
[Code]....
View 1 Replies
View Related
Mar 7, 2010
I have an issue regarding nested entity.
I have a nested entity block reference. In this entity I have three blocks. if I change any of the block reference attribute definition in the nested block reference then it is changing the original block itself.
Actually I am getting the handle of the selected block reference in the nested Entity. and change the attribute reference later. but it is making change in the block itself and other block reference too.
Here is my
static public void CONTACTS()
{
Document doc = Autodesk.AutoCAD.ApplicationServices.Application.DocumentManager.MdiActiveDocument;
Editor ed = doc.Editor;
string contactName = string.Empty;//to hold contact name, from xdata
[code].......
View 3 Replies
View Related
May 24, 2012
I have tried to use intersectwith to locate text (MText or DBText) near a block reference. Some times it works and some times it does not. The hard part for me is understanding why it occasionally works when most examples are just duplicates with modified text and attributes.
My block reference has 4 attributes to the left (Right Justified) of a circle and 2 attributes inside the circle. The text objects are used by some CAD operators instead of the upper 2 lines of attributtes. (Guess they dont know how to modify attributes) I want to locate these texts and insert text into the corresponding attribute.
Block Reference:
Att 1 |'''''''| <-- CAD User will insert a txt over Att 1 and Att 2,
Att 2 | | <-- both attributes are usally left blank or contain a space
Att 3 | |
Att 4 |.....|
View 8 Replies
View Related
Apr 5, 2012
I have text in my title block that references part properties. If I have several different part and assembly base views on a sheet, how do I control which one the title block references? It defaults to the first one that was placed. I am using 2011 Pro.
View 1 Replies
View Related
Sep 21, 2011
Is is possible to get the block handle from an attribute reference? I get the attribute reference from a previously stored attribute collection. I did try attref.BlockId.Handle.Value.ToString(), but it gives a different value, not the block's id.
View 2 Replies
View Related
Apr 23, 2013
I need to select a block in AutoCAD, and move it up or down vertically. I can get to the point where I have the user select a particular block, but after that, how do I get a reference to the block selected so I can move it up or down?
View 1 Replies
View Related
Feb 7, 2013
I have a block that I use as hatch (using superhatch), so the block appears several times. At the border of the hatch I want to fix some of the lines.
If I try to ungroup & explode the hatch, then the block appears outside of the hatch boundry.
So my question is if I can fix the lines so the hatch remains whole.
View 8 Replies
View Related
Dec 2, 2013
Is there a possibility to use "Dynamic Blocks" as an "External Reference" having the ability to use their features at the same time?
The thing is I have dwg1 and dwg2 files and in them I use "Dynamic Block1". Whenever I update "Dynamic Block1" in one of the dwg files I have to go to "design center" and update the "Dynamic Block1" in other dwg file.
View 9 Replies
View Related
Jul 26, 2013
AutoDesk 2014 . I am currently trying to design in iphone case. So I downloaded a replica iPhone from grab cad:
[URL]
I imported it and formed a solid around it, now I am trying to subtract the phone from the solid so it perfectly fits within the case. It will not let me subtract it though because the phone is a reference block and the square around it is a solid.
View 1 Replies
View Related
Jun 6, 2011
I create a set of points in a drawing and create each point as a block reference containing the point, text and probably something else. Also I would like to use different symbols for points and each of the symbols is defined as a block definition, and for each point I create a block reference according to the symbol type. The question is if is there any way to "combine" block definitions/references? I mean, I have common block definition for all points, whis defines somethin common for all of them. Also I have different symbols for each type of points and each symbol is defined separately as a block. But when a final point is created (containing common definitions and type-dependent symbol) I want to have it as a single block.
View 5 Replies
View Related
Apr 13, 2013
I'm a newbie in dotnet and want to now if is possible to iterate through items of a block reference.
My problem is the following : I explode a block reference in dotnet (it works well) and I want to change the items layer that compose the bloc reference. It's the reason why i need to browse items of this block.
View 5 Replies
View Related
Apr 12, 2007
I'm trying to use a Selection Filter on Block Reference XData value. But I get no hits, it works fine with Lines and Polylines that has the same kind of XData.
Is it a bug or do I have to define my Selection Filter differently when working with Block Reference?
Here is a part of the code :
TypedValue[] flt = new TypedValue[]
{
new TypedValue(-4, " new TypedValue(-4, " new TypedValue(8, "POLYLINE_LAYER"),
new TypedValue(1001, "Object_Id"),
new TypedValue(1000, "166448"),
new TypedValue(-4, "AND>"),
[code].......
View 3 Replies
View Related
Aug 23, 2013
I have a small vba sub wich changes the color and layer of all entities inside a block. It seems to work pretty well for the majority of blocks, but then if I try that on a dynamic block, the definition is correctly altered, but the references aren't updated...
I know for a fact that the definition has been correctly modified because if I type bedit, I can see the definition is modified. Then, in the block editor, if I save the block, the references are correctly updated.
How to force references to update after I made the modifications inside the definition ?
I searched for methods within the VBA Reference and I tried blockRef.Update but it doesn't seem to have any effect.
View 2 Replies
View Related