Edit table from Excel

Edit table from Excel

Amriya_Exe
Advocate Advocate
550 Views
9 Replies
Message 1 of 10

Edit table from Excel

Amriya_Exe
Advocate
Advocate

In my task I have 40+ layouts in one single DWG file have same table but I have to edit some cell numbers

H1 S1 AD1 AO1 H15 S15 AD15 AO15 H29 S29

from excel file. can someone help me with script that can read my layout name and fill data from excel.

Amriya_Exe_0-1709263335386.png

 

0 Likes
551 Views
9 Replies
Replies (9)
Message 2 of 10

hosneyalaa
Advisor
Advisor

Can you try this

Attributes-1.png

 

 

And you can attached example drawing 

0 Likes
Message 3 of 10

Amriya_Exe
Advocate
Advocate

Thank you for reply Please check this file I need to edit data in table so attribute option will work?

Amriya_Exe_0-1709399344107.png

 

0 Likes
Message 4 of 10

Amriya_Exe
Advocate
Advocate

Someone please share the solution for this table editing work for all layouts.

0 Likes
Message 5 of 10

Sea-Haven
Mentor
Mentor

It appears that there is a pattern in the real big table, rows are every 14, columns are spaced at 11. I am just not sure that this is like just a start for another 5 requests as happens so many times. It is easy to read a cell 0,8 = 9965, then send to Excel.

 

Can you confirm this is the only thing you want to do with this table ?

Message 6 of 10

Amriya_Exe
Advocate
Advocate
Yes target cells are fixed
H1 S1 AD1 AO1 H15 S15 AD15 AO15 H29 S29
But in some case we can adjust if required.
0 Likes
Message 7 of 10

Amriya_Exe
Advocate
Advocate

@hosneyalaa Please look here if you can help any.

0 Likes
Message 8 of 10

Sea-Haven
Mentor
Mentor

When using lisp and looking at a table similar for excel can use row,column not the cell adress like "H1" which is 0,8 so then next is 0,19 repeat 4 times, then becomes 14,8 14,19 etc. Much easier to do the repeat pattern.

 

Which is what I commented about in prior post.

 

 

; (VLA-GETTEXT OBJ row col)
(VLA-GETTEXT OBJ 0 7)
"9965"

 

 

Have added to my To do list, some one else may do something sooner, need a couple of days.

0 Likes
Message 9 of 10

Amriya_Exe
Advocate
Advocate
OK no problem I will wait.
0 Likes
Message 10 of 10

Sea-Haven
Mentor
Mentor

I read the post backwards yes Excel can control CAD via a macro. Have done circles lines and plines as a simple test.

 

Ok thanks to Gile there is a convert H8 to row,col. The reason I ask is does the excel /Cad cell address change ? Its not a problem just dont want to go down some direction and have to change methods, it will read the excel from CAD.

 

Need a test Excel that matches a dwg, for testing.

 

I refer to Cad as works with Bricscad and Autocad, plus looking at Libreoffice Calc also.