Community
AutoCAD Forum
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Automatic ascending order to property titles of a block?

9 REPLIES 9
Reply
Message 1 of 10
jodysavage
509 Views, 9 Replies

Automatic ascending order to property titles of a block?

Hi all,

 

For a project I'm on, I have to place blocks which are just locations of where photos were taken however in the properties of the block, there is a reference box (just a numbered ascending order e.g. 1,2,3,4...) and a file name box which is the exact file name that matches to the correct photo (e.g. 'AH_0_ (1).jpg').

 

It is extremely time consuming and mind numbing to copy the block and then define the properties of it for every one (there are near to 100 blocks per building). Is there a lisp or script that can automatically ascend these numbers and just allow me to constantly copy the blocks to their positions?

Labels (3)
9 REPLIES 9
Message 2 of 10

You can insert blocks in dwg, export their attributes to csv/txt with the ATTOUT command from Express, define the numbers in Excel or the like, and import in the attributes in dwg with the ATTIN command.

 

For attribute numbering when block inserting, there is a Lee Mac program that is about 20 years old. Search gives many others - you should try them.

 

 


-- Alexander, private person, pacifist, english only with translator 🙂 --

Object-modeling _ odclass-odedit.com _ Help

Message 3 of 10
paullimapa
in reply to: jodysavage

Could you share a sample drawing with a few of these images already positioned and the block that has the attributes that would hold the number and the image filename? Be sure to use Etransmit command so the images would be automatically included with the drawing for posting here 


Paul Li
IT Specialist
@The Office
Apps & Publications | Video Demos
Message 4 of 10
jodysavage
in reply to: paullimapa

Hi Paul,

 

Thanks for the response. Attached is a test file with a generic floor plan however scattered across are the photograph blocks I was talking about. Let me know if you need anything else.

 

Thanks.

Message 5 of 10
pendean
in reply to: jodysavage

@jodysavage  So you are just wanting an auto-numbering ability? Blocks with attributes or TEXT, this freebie from the Autodesk App Store will do that for you

 

https://apps.autodesk.com/ACD/en/Detail/Index?id=8051485828049059617&appLang=en&os=Win32_64

 

 

Message 6 of 10
jodysavage
in reply to: pendean

Hi @pendean,

 

Thanks for the reply. My block is quite specific and has additional attributes as seen in the screenshot in my original post. It has 2 different naming attributes that I would like to be incremented, one is just the number (1,2,3,4 etc) and the other is the file name of the photo that said block relates to. The file name would be, for example, AH_2_ (11). "AH" is the initials of the building, the "2" is for the 2nd floor and the "(11)" relates to the number of the photograph which is the same number as the first attribute. Would this programme be able to run with that? It's just that I'd have to get it approved through our IT to download it.

 

Thanks.

 

 

Message 7 of 10

Hi Alexander,

 

Thanks very much for your reply. The programme works so well however do you know if it's possible to do two attributes on it?

 

I can create increments on one attribute such as the file name of my block however I still have one more I need to increment which is just the number. Both attributes are the same number but annoyingly, the client need this specific block.

 

As you can see on the attached screenshot, the programme works for the "FileName" attribute however I also need to have the "REFERENCE" attribute increase in increments too otherwise I still have to go back and change each block individually.

 

Please don't hesitate to ask any questions.

 

Thanks.

Message 8 of 10
paullimapa
in reply to: jodysavage

Thanks for the sample dwg

In this sample, there are a total of 19 blocks each representing an image starting # at 1 and ending at 19.

Question:

1. Are all the drawings similar where it'll always start with image #1 and never skip a #?

2. You'll never have a duplicate where more than one block will show the same image #?

 


Paul Li
IT Specialist
@The Office
Apps & Publications | Video Demos
Message 9 of 10
pendean
in reply to: jodysavage


@jodysavage wrote:

Hi @pendean,

 

Thanks for the reply. My block is quite specific and has additional attributes as seen in the screenshot in my original post. It has 2 different naming attributes that I would like to be incremented, one is just the number (1,2,3,4 etc)....


pendean_0-1717433311307.png

 

 


@jodysavage wrote:

.... The file name would be, for example, AH_2_ (11). "AH" is the initials of the building, the "2" is for the 2nd floor and the "(11)" relates to the number of the photograph which is the same number as the first attribute....


That would be a second pass with the same add-on (your FILENAME attribute is set to hidden apparently)

pendean_1-1717433718096.png

 

 

 

 

 

 

 

 

 

 

 

 

Message 10 of 10
paullimapa
in reply to: jodysavage

Give attached lisp function a try.

Save IAP.lsp to a folder location located under Options > Files > Support File Search Path & Trusted Locations.

Then to load drag & drop IAP.lsp onto the drawing area or at command prompt enter:

 

 

(load"IAP")

 

 

Then to run it enter at command prompt:
IAP

 


Paul Li
IT Specialist
@The Office
Apps & Publications | Video Demos

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Forma Design Contest


AutoCAD Beta