Jump to content

Attributes to Excel


mitchellrodhous

Recommended Posts

After working with the data extraction to get some date converted to excel I was wondering If It could be in a quicker way?

By using data extarction I create objects with several data. Now To extract something to excel I always have to repeat the same handeling.

Wondering if anyone has got a lisp solition for this?

 

Regards MR

Link to comment
Share on other sites

  • Replies 24
  • Created
  • Last Reply

Top Posters In This Topic

  • Lee Mac

    12

  • mitchellrodhous

    12

  • fixo

    1

Popular Days

Top Posters In This Topic

Posted Images

Lee I have to say that's an impressive piece of art.. only (probobly I am using it wrong) I only get after extracting an filepath like >>: C:\Documents and Settings\*******\Bureaublad\Drawing1.dwg in my row E from excel. How can I let it convert the attributes? if I am using wrong just let me know...

 

Regards MR

Link to comment
Share on other sites

I'm not sure what you mean 'convert the attributes'?

 

My program will extract all/specified attributes from specified blocks in the current drawing or a whole directory (and subdirectories) of drawings; and write these attributes to a new Excel file for the user to save as he/she pleases.

 

Lee

Link to comment
Share on other sites

Well I am making blocks with the attechment lisp.

After drawing You get an image like image 1 but than probebly in 2d view. This blocks all have theire own attributes. (Reference, Length, Width and Thickness) as you can see on the image 1, and in the drawing if you play my lisp.

But than If I use command DATAEXTRACTION in cad2011 I have to select my objects than after selecting fellowing the 8 steps to complete a table. See result I want to get on image 2.

Now I was thinking if theire was a lisp routine to create that kind of table, (in drawing or EXCEL Sheet) with just one single click and selecting the objects. without my 8 steps...

Hope I am a bit clearer right know.

See your reaction forward,

 

Regards MR

Cabinet.LSP

1.jpg

2.jpg

Link to comment
Share on other sites

Yes - my program can write the attributes to Excel - the number of steps will be determined by whether you know the block name/tag name etc.

 

If you know the block name: open a new drawing, and run my program - enter the name of the block whose attributes you wish to extract; select a directory of drawings to process. Excel will then be automatically opened and the data written.

 

If you don't know the block name, perhaps run my program in a drawing containing the blocks and select the blocks you wish to extract from; then click 'Current Drawing' and the data will be written.

 

You can play around with the modes depending on how you wish the data to be presented.

 

Lee

Link to comment
Share on other sites

Well I played your lisp fellowing the images>>

Maybe you can see by images what I am doing wrong

 

Regards MR

1.JPG

2.JPG

3.JPG

4.JPG

5.jpg

Link to comment
Share on other sites

Aah I see you can't select the files... That doesn't work I have really to fill In the name of this block... Isn't theire a improvement needed Lee?

Regards MR

 

PS1: another improvement could be that it also exports the block name to excel?

Link to comment
Share on other sites

Aah I see you can't select the files... That doesn't work I have really to fill In the name of this block... Isn't theire a improvement needed Lee?

Regards MR

 

PS1: another improvement could be that it also exports the block name to excel?

 

I'm not sure what you are talking about?

 

When in 'drawing list mode', the block name is not written (purely because in this mode, most users will be extracting the same title block everytime, and don't wish to see it written), however the block name will be written when using the other modes.

 

What do you mean select the files?

Link to comment
Share on other sites

Yep you're correct It wil fill in the correct block name, but I have still need to typ the blocknames to get everything correct exported. If I have an drawing with more than 300 objects/blocks It would not be great right?

So I want to select the blocks with a crossing...

 

Regards MR

Link to comment
Share on other sites

Aah I see you can't select the files... That doesn't work I have really to fill In the name of this block... Isn't theire[sic] a improvement needed Lee?

 

I'm not sure that you know how to use the program. :glare:

Link to comment
Share on other sites

Yep you're correct It wil fill in the correct block name, but I have still need to typ the blocknames to get everything correct exported. If I have an drawing with more than 300 objects/blocks It would not be great right?

So I want to select the blocks with a crossing...

 

Regards MR

 

You can select the blocks.

Link to comment
Share on other sites

Yeah I know how it works this programm, and I can select the blocks... You're correct about taht, only If export to excel the result is like the image below:

 

If I typ the name of the block and add it manually, not by crossing or selecting it does work.

5.jpg

Link to comment
Share on other sites

Yeah ofcourse, just open your autocad and play my lisp routine Cabinet.lsp. cammand is kast. the lisp will ask for different dimensions. theese dimensions are in milimeters and will create the cabinet I am talking about. Than run your own programm. If you typ in your routine as blockname top1 it will add this Top1 correct! etc with the other blocks of the cabinet, Bottom1, Rightside1, Leftside1.

 

Now try the same with a crossing over my cabinet (selecting the whole cabinet in once).. the difference between theese two you can will see on image 1 and 2 below.

The 1 shows all the attributes and the other shows ALL TAGS.

 

By crossing It wont work with me..

 

Regards MR

Cabinet.LSP

1.JPG

2.JPG

Link to comment
Share on other sites

Thanks, I shall have to look.

 

Could you please remove my program from your post, as I would rather it be referenced by a link if necessary, to save from confusion should I update the program.

 

Lee

Link to comment
Share on other sites

Thanks, I shall have to look.

 

Could you please remove my program from your post,

Lee

 

It's done Lee;)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...